boris 1.0.0.beta.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (88) hide show
  1. data/LICENSE.md +9 -0
  2. data/README.md +94 -0
  3. data/boris.gemspec +28 -0
  4. data/doc/Array.html +437 -0
  5. data/doc/Boris.html +230 -0
  6. data/doc/Boris/ConnectionAlreadyActive.html +123 -0
  7. data/doc/Boris/ConnectionFailed.html +127 -0
  8. data/doc/Boris/Connector.html +794 -0
  9. data/doc/Boris/InvalidCredentials.html +131 -0
  10. data/doc/Boris/InvalidOption.html +123 -0
  11. data/doc/Boris/InvalidTargetName.html +123 -0
  12. data/doc/Boris/Lumberjack.html +466 -0
  13. data/doc/Boris/MissingCredentials.html +123 -0
  14. data/doc/Boris/NoActiveConnection.html +123 -0
  15. data/doc/Boris/NoProfileDetected.html +123 -0
  16. data/doc/Boris/Options.html +783 -0
  17. data/doc/Boris/Profiles.html +117 -0
  18. data/doc/Boris/Profiles/Linux.html +1151 -0
  19. data/doc/Boris/Profiles/RedHat.html +875 -0
  20. data/doc/Boris/Profiles/Solaris.html +1230 -0
  21. data/doc/Boris/Profiles/Structure.html +2050 -0
  22. data/doc/Boris/Profiles/UNIX.html +893 -0
  23. data/doc/Boris/Profiles/Windows.html +1846 -0
  24. data/doc/Boris/Profiles/Windows/Windows2003.html +304 -0
  25. data/doc/Boris/Profiles/Windows/Windows2008.html +379 -0
  26. data/doc/Boris/Profiles/Windows/Windows2012.html +304 -0
  27. data/doc/Boris/SNMPConnector.html +512 -0
  28. data/doc/Boris/SSHConnector.html +633 -0
  29. data/doc/Boris/Target.html +2002 -0
  30. data/doc/Boris/WMIConnector.html +1134 -0
  31. data/doc/BorisLogger.html +217 -0
  32. data/doc/Hash.html +195 -0
  33. data/doc/String.html +1246 -0
  34. data/doc/_index.html +420 -0
  35. data/doc/class_list.html +53 -0
  36. data/doc/css/common.css +1 -0
  37. data/doc/css/full_list.css +57 -0
  38. data/doc/css/style.css +328 -0
  39. data/doc/file.README.html +183 -0
  40. data/doc/file_list.html +55 -0
  41. data/doc/frames.html +28 -0
  42. data/doc/index.html +183 -0
  43. data/doc/js/app.js +214 -0
  44. data/doc/js/full_list.js +173 -0
  45. data/doc/js/jquery.js +4 -0
  46. data/doc/method_list.html +1468 -0
  47. data/doc/top-level-namespace.html +126 -0
  48. data/lib/boris.rb +30 -0
  49. data/lib/boris/connectors.rb +47 -0
  50. data/lib/boris/connectors/snmp.rb +56 -0
  51. data/lib/boris/connectors/ssh.rb +110 -0
  52. data/lib/boris/connectors/wmi.rb +186 -0
  53. data/lib/boris/errors.rb +17 -0
  54. data/lib/boris/helpers/array.rb +63 -0
  55. data/lib/boris/helpers/constants.rb +20 -0
  56. data/lib/boris/helpers/hash.rb +8 -0
  57. data/lib/boris/helpers/scrubber.rb +51 -0
  58. data/lib/boris/helpers/string.rb +130 -0
  59. data/lib/boris/lumberjack.rb +47 -0
  60. data/lib/boris/options.rb +86 -0
  61. data/lib/boris/profiles/linux/redhat.rb +77 -0
  62. data/lib/boris/profiles/linux_core.rb +216 -0
  63. data/lib/boris/profiles/unix/solaris.rb +307 -0
  64. data/lib/boris/profiles/unix_core.rb +85 -0
  65. data/lib/boris/profiles/windows/windows2003.rb +15 -0
  66. data/lib/boris/profiles/windows/windows2008.rb +23 -0
  67. data/lib/boris/profiles/windows/windows2012.rb +15 -0
  68. data/lib/boris/profiles/windows_core.rb +530 -0
  69. data/lib/boris/structure.rb +167 -0
  70. data/lib/boris/target.rb +340 -0
  71. data/test/connector_tests/test_snmp.rb +35 -0
  72. data/test/connector_tests/test_ssh.rb +51 -0
  73. data/test/connector_tests/test_wmi.rb +129 -0
  74. data/test/helper_tests/test_array.rb +25 -0
  75. data/test/helper_tests/test_hash.rb +10 -0
  76. data/test/helper_tests/test_string.rb +136 -0
  77. data/test/profile_tests/test_core_skeleton +107 -0
  78. data/test/profile_tests/test_linux_core.rb +331 -0
  79. data/test/profile_tests/test_redhat.rb +134 -0
  80. data/test/profile_tests/test_solaris.rb +523 -0
  81. data/test/profile_tests/test_unix_core.rb +117 -0
  82. data/test/profile_tests/test_windows.rb +536 -0
  83. data/test/setup_tests.rb +14 -0
  84. data/test/test_all.rb +8 -0
  85. data/test/test_options.rb +44 -0
  86. data/test/test_structure.rb +136 -0
  87. data/test/test_target.rb +146 -0
  88. metadata +241 -0
@@ -0,0 +1,893 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Module: Boris::Profiles::UNIX
8
+
9
+ &mdash; Documentation by YARD 0.8.3
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ hasFrames = window.top.frames.main ? true : false;
19
+ relpath = '../../';
20
+ framesUrl = "../../frames.html#!" + escape(window.location.href);
21
+ </script>
22
+
23
+
24
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
25
+
26
+ <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
27
+
28
+
29
+ </head>
30
+ <body>
31
+ <div id="header">
32
+ <div id="menu">
33
+
34
+ <a href="../../_index.html">Index (U)</a> &raquo;
35
+ <span class='title'><span class='object_link'><a href="../../Boris.html" title="Boris (module)">Boris</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Profiles.html" title="Boris::Profiles (module)">Profiles</a></span></span>
36
+ &raquo;
37
+ <span class="title">UNIX</span>
38
+
39
+
40
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
41
+ </div>
42
+
43
+ <div id="search">
44
+
45
+ <a class="full_list_link" id="class_list_link"
46
+ href="../../class_list.html">
47
+ Class List
48
+ </a>
49
+
50
+ <a class="full_list_link" id="method_list_link"
51
+ href="../../method_list.html">
52
+ Method List
53
+ </a>
54
+
55
+ <a class="full_list_link" id="file_list_link"
56
+ href="../../file_list.html">
57
+ File List
58
+ </a>
59
+
60
+ </div>
61
+ <div class="clear"></div>
62
+ </div>
63
+
64
+ <iframe id="search_frame"></iframe>
65
+
66
+ <div id="content"><h1>Module: Boris::Profiles::UNIX
67
+
68
+
69
+
70
+ </h1>
71
+
72
+ <dl class="box">
73
+
74
+
75
+
76
+
77
+
78
+ <dt class="r1">Includes:</dt>
79
+ <dd class="r1"><span class='object_link'><a href="Structure.html" title="Boris::Profiles::Structure (module)">Structure</a></span></dd>
80
+
81
+
82
+
83
+
84
+ <dt class="r2">Included in:</dt>
85
+ <dd class="r2"><span class='object_link'><a href="Solaris.html" title="Boris::Profiles::Solaris (module)">Solaris</a></span></dd>
86
+
87
+
88
+
89
+ <dt class="r1 last">Defined in:</dt>
90
+ <dd class="r1 last">lib/boris/profiles/unix_core.rb</dd>
91
+
92
+ </dl>
93
+ <div class="clear"></div>
94
+
95
+
96
+
97
+
98
+
99
+
100
+
101
+ <h2>Instance Attribute Summary</h2>
102
+
103
+ <h3 class="inherited">Attributes included from <span class='object_link'><a href="Structure.html" title="Boris::Profiles::Structure (module)">Structure</a></span></h3>
104
+ <p class="inherited"><span class='object_link'><a href="Structure.html#file_systems-instance_method" title="Boris::Profiles::Structure#file_systems (method)">#file_systems</a></span>, <span class='object_link'><a href="Structure.html#hardware-instance_method" title="Boris::Profiles::Structure#hardware (method)">#hardware</a></span>, <span class='object_link'><a href="Structure.html#hosted_shares-instance_method" title="Boris::Profiles::Structure#hosted_shares (method)">#hosted_shares</a></span>, <span class='object_link'><a href="Structure.html#installed_applications-instance_method" title="Boris::Profiles::Structure#installed_applications (method)">#installed_applications</a></span>, <span class='object_link'><a href="Structure.html#installed_patches-instance_method" title="Boris::Profiles::Structure#installed_patches (method)">#installed_patches</a></span>, <span class='object_link'><a href="Structure.html#installed_services-instance_method" title="Boris::Profiles::Structure#installed_services (method)">#installed_services</a></span>, <span class='object_link'><a href="Structure.html#local_user_groups-instance_method" title="Boris::Profiles::Structure#local_user_groups (method)">#local_user_groups</a></span>, <span class='object_link'><a href="Structure.html#network_id-instance_method" title="Boris::Profiles::Structure#network_id (method)">#network_id</a></span>, <span class='object_link'><a href="Structure.html#network_interfaces-instance_method" title="Boris::Profiles::Structure#network_interfaces (method)">#network_interfaces</a></span>, <span class='object_link'><a href="Structure.html#operating_system-instance_method" title="Boris::Profiles::Structure#operating_system (method)">#operating_system</a></span></p>
105
+
106
+
107
+
108
+ <h3 class="inherited">Attributes included from <span class='object_link'><a href="../Lumberjack.html" title="Boris::Lumberjack (module)">Lumberjack</a></span></h3>
109
+ <p class="inherited"><span class='object_link'><a href="../Lumberjack.html#logger-instance_method" title="Boris::Lumberjack#logger (method)">#logger</a></span></p>
110
+
111
+
112
+
113
+ <h2>
114
+ Class Method Summary
115
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
116
+ </h2>
117
+
118
+ <ul class="summary">
119
+
120
+ <li class="public ">
121
+ <span class="summary_signature">
122
+
123
+ <a href="#connection_type-class_method" title="connection_type (class method)">+ (Object) <strong>connection_type</strong> </a>
124
+
125
+
126
+
127
+ </span>
128
+
129
+
130
+
131
+
132
+
133
+
134
+
135
+
136
+
137
+ <span class="summary_desc"><div class='inline'></div></span>
138
+
139
+ </li>
140
+
141
+
142
+ <li class="public ">
143
+ <span class="summary_signature">
144
+
145
+ <a href="#matches_target%3F-class_method" title="matches_target? (class method)">+ (Boolean) <strong>matches_target?</strong>(connector) </a>
146
+
147
+
148
+
149
+ </span>
150
+
151
+
152
+
153
+
154
+
155
+
156
+
157
+
158
+
159
+ <span class="summary_desc"><div class='inline'></div></span>
160
+
161
+ </li>
162
+
163
+
164
+ </ul>
165
+
166
+ <h2>
167
+ Instance Method Summary
168
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
169
+ </h2>
170
+
171
+ <ul class="summary">
172
+
173
+ <li class="public ">
174
+ <span class="summary_signature">
175
+
176
+ <a href="#get_file_systems-instance_method" title="#get_file_systems (instance method)">- (Object) <strong>get_file_systems</strong> </a>
177
+
178
+
179
+
180
+ </span>
181
+
182
+
183
+
184
+
185
+
186
+
187
+
188
+
189
+
190
+ <span class="summary_desc"><div class='inline'></div></span>
191
+
192
+ </li>
193
+
194
+
195
+ <li class="public ">
196
+ <span class="summary_signature">
197
+
198
+ <a href="#get_hardware-instance_method" title="#get_hardware (instance method)">- (Object) <strong>get_hardware</strong> </a>
199
+
200
+
201
+
202
+ </span>
203
+
204
+
205
+
206
+
207
+
208
+
209
+
210
+
211
+
212
+ <span class="summary_desc"><div class='inline'></div></span>
213
+
214
+ </li>
215
+
216
+
217
+ <li class="public ">
218
+ <span class="summary_signature">
219
+
220
+ <a href="#get_hosted_shares-instance_method" title="#get_hosted_shares (instance method)">- (Object) <strong>get_hosted_shares</strong> </a>
221
+
222
+
223
+
224
+ </span>
225
+
226
+
227
+
228
+
229
+
230
+
231
+
232
+
233
+
234
+ <span class="summary_desc"><div class='inline'></div></span>
235
+
236
+ </li>
237
+
238
+
239
+ <li class="public ">
240
+ <span class="summary_signature">
241
+
242
+ <a href="#get_installed_applications-instance_method" title="#get_installed_applications (instance method)">- (Object) <strong>get_installed_applications</strong> </a>
243
+
244
+
245
+
246
+ </span>
247
+
248
+
249
+
250
+
251
+
252
+
253
+
254
+
255
+
256
+ <span class="summary_desc"><div class='inline'></div></span>
257
+
258
+ </li>
259
+
260
+
261
+ <li class="public ">
262
+ <span class="summary_signature">
263
+
264
+ <a href="#get_installed_patches-instance_method" title="#get_installed_patches (instance method)">- (Object) <strong>get_installed_patches</strong> </a>
265
+
266
+
267
+
268
+ </span>
269
+
270
+
271
+
272
+
273
+
274
+
275
+
276
+
277
+
278
+ <span class="summary_desc"><div class='inline'></div></span>
279
+
280
+ </li>
281
+
282
+
283
+ <li class="public ">
284
+ <span class="summary_signature">
285
+
286
+ <a href="#get_installed_services-instance_method" title="#get_installed_services (instance method)">- (Object) <strong>get_installed_services</strong> </a>
287
+
288
+
289
+
290
+ </span>
291
+
292
+
293
+
294
+
295
+
296
+
297
+
298
+
299
+
300
+ <span class="summary_desc"><div class='inline'></div></span>
301
+
302
+ </li>
303
+
304
+
305
+ <li class="public ">
306
+ <span class="summary_signature">
307
+
308
+ <a href="#get_local_user_groups-instance_method" title="#get_local_user_groups (instance method)">- (Object) <strong>get_local_user_groups</strong> </a>
309
+
310
+
311
+
312
+ </span>
313
+
314
+
315
+
316
+
317
+
318
+
319
+
320
+
321
+
322
+ <span class="summary_desc"><div class='inline'></div></span>
323
+
324
+ </li>
325
+
326
+
327
+ <li class="public ">
328
+ <span class="summary_signature">
329
+
330
+ <a href="#get_network_id-instance_method" title="#get_network_id (instance method)">- (Object) <strong>get_network_id</strong> </a>
331
+
332
+
333
+
334
+ </span>
335
+
336
+
337
+
338
+
339
+
340
+
341
+
342
+
343
+
344
+ <span class="summary_desc"><div class='inline'></div></span>
345
+
346
+ </li>
347
+
348
+
349
+ <li class="public ">
350
+ <span class="summary_signature">
351
+
352
+ <a href="#get_network_interfaces-instance_method" title="#get_network_interfaces (instance method)">- (Object) <strong>get_network_interfaces</strong> </a>
353
+
354
+
355
+
356
+ </span>
357
+
358
+
359
+
360
+
361
+
362
+
363
+
364
+
365
+
366
+ <span class="summary_desc"><div class='inline'></div></span>
367
+
368
+ </li>
369
+
370
+
371
+ <li class="public ">
372
+ <span class="summary_signature">
373
+
374
+ <a href="#get_operating_system-instance_method" title="#get_operating_system (instance method)">- (Object) <strong>get_operating_system</strong> </a>
375
+
376
+
377
+
378
+ </span>
379
+
380
+
381
+
382
+
383
+
384
+
385
+
386
+
387
+
388
+ <span class="summary_desc"><div class='inline'></div></span>
389
+
390
+ </li>
391
+
392
+
393
+ </ul>
394
+
395
+
396
+
397
+
398
+
399
+
400
+
401
+
402
+
403
+
404
+
405
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="Structure.html" title="Boris::Profiles::Structure (module)">Structure</a></span></h3>
406
+ <p class="inherited"><span class='object_link'><a href="Structure.html#file_system_template-instance_method" title="Boris::Profiles::Structure#file_system_template (method)">#file_system_template</a></span>, <span class='object_link'><a href="Structure.html#hosted_share_template-instance_method" title="Boris::Profiles::Structure#hosted_share_template (method)">#hosted_share_template</a></span>, <span class='object_link'><a href="Structure.html#installed_application_template-instance_method" title="Boris::Profiles::Structure#installed_application_template (method)">#installed_application_template</a></span>, <span class='object_link'><a href="Structure.html#installed_patch_template-instance_method" title="Boris::Profiles::Structure#installed_patch_template (method)">#installed_patch_template</a></span>, <span class='object_link'><a href="Structure.html#installed_service_template-instance_method" title="Boris::Profiles::Structure#installed_service_template (method)">#installed_service_template</a></span>, <span class='object_link'><a href="Structure.html#local_user_groups_template-instance_method" title="Boris::Profiles::Structure#local_user_groups_template (method)">#local_user_groups_template</a></span>, <span class='object_link'><a href="Structure.html#network_interface_template-instance_method" title="Boris::Profiles::Structure#network_interface_template (method)">#network_interface_template</a></span>, <span class='object_link'><a href="Structure.html#scrub_data%21-instance_method" title="Boris::Profiles::Structure#scrub_data! (method)">#scrub_data!</a></span></p>
407
+
408
+
409
+
410
+
411
+
412
+
413
+
414
+
415
+
416
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="../Lumberjack.html" title="Boris::Lumberjack (module)">Lumberjack</a></span></h3>
417
+ <p class="inherited"><span class='object_link'><a href="../Lumberjack.html#debug-instance_method" title="Boris::Lumberjack#debug (method)">#debug</a></span>, <span class='object_link'><a href="../Lumberjack.html#error-instance_method" title="Boris::Lumberjack#error (method)">#error</a></span>, <span class='object_link'><a href="../Lumberjack.html#fatal-instance_method" title="Boris::Lumberjack#fatal (method)">#fatal</a></span>, <span class='object_link'><a href="../Lumberjack.html#info-instance_method" title="Boris::Lumberjack#info (method)">#info</a></span>, <span class='object_link'><a href="../Lumberjack.html#warn-instance_method" title="Boris::Lumberjack#warn (method)">#warn</a></span></p>
418
+
419
+
420
+ <div id="class_method_details" class="method_details_list">
421
+ <h2>Class Method Details</h2>
422
+
423
+
424
+ <div class="method_details first">
425
+ <h3 class="signature first" id="connection_type-class_method">
426
+
427
+ + (<tt>Object</tt>) <strong>connection_type</strong>
428
+
429
+
430
+
431
+
432
+
433
+ </h3><table class="source_code">
434
+ <tr>
435
+ <td>
436
+ <pre class="lines">
437
+
438
+
439
+ 7
440
+ 8
441
+ 9</pre>
442
+ </td>
443
+ <td>
444
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 7</span>
445
+
446
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_connection_type'>connection_type</span>
447
+ <span class='const'>Boris</span><span class='op'>::</span><span class='const'>SSHConnector</span>
448
+ <span class='kw'>end</span></pre>
449
+ </td>
450
+ </tr>
451
+ </table>
452
+ </div>
453
+
454
+ <div class="method_details ">
455
+ <h3 class="signature " id="matches_target?-class_method">
456
+
457
+ + (<tt>Boolean</tt>) <strong>matches_target?</strong>(connector)
458
+
459
+
460
+
461
+
462
+
463
+ </h3><div class="docstring">
464
+ <div class="discussion">
465
+
466
+
467
+ </div>
468
+ </div>
469
+ <div class="tags">
470
+
471
+ <p class="tag_title">Returns:</p>
472
+ <ul class="return">
473
+
474
+ <li>
475
+
476
+
477
+ <span class='type'>(<tt>Boolean</tt>)</span>
478
+
479
+
480
+
481
+ </li>
482
+
483
+ </ul>
484
+
485
+ </div><table class="source_code">
486
+ <tr>
487
+ <td>
488
+ <pre class="lines">
489
+
490
+
491
+ 11
492
+ 12
493
+ 13</pre>
494
+ </td>
495
+ <td>
496
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 11</span>
497
+
498
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_matches_target?'>matches_target?</span><span class='lparen'>(</span><span class='id identifier rubyid_connector'>connector</span><span class='rparen'>)</span>
499
+ <span class='kw'>return</span> <span class='kw'>true</span> <span class='kw'>if</span> <span class='id identifier rubyid_connector'>connector</span><span class='period'>.</span><span class='id identifier rubyid_value_at'>value_at</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>uname -a</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='op'>!~</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>linux</span><span class='regexp_end'>/i</span></span>
500
+ <span class='kw'>end</span></pre>
501
+ </td>
502
+ </tr>
503
+ </table>
504
+ </div>
505
+
506
+ </div>
507
+
508
+ <div id="instance_method_details" class="method_details_list">
509
+ <h2>Instance Method Details</h2>
510
+
511
+
512
+ <div class="method_details first">
513
+ <h3 class="signature first" id="get_file_systems-instance_method">
514
+
515
+ - (<tt>Object</tt>) <strong>get_file_systems</strong>
516
+
517
+
518
+
519
+
520
+
521
+ </h3><table class="source_code">
522
+ <tr>
523
+ <td>
524
+ <pre class="lines">
525
+
526
+
527
+ 15
528
+ 16
529
+ 17
530
+ 18
531
+ 19
532
+ 20
533
+ 21
534
+ 22
535
+ 23
536
+ 24
537
+ 25
538
+ 26
539
+ 27
540
+ 28
541
+ 29
542
+ 30</pre>
543
+ </td>
544
+ <td>
545
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 15</span>
546
+
547
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_file_systems'>get_file_systems</span>
548
+ <span class='kw'>super</span>
549
+
550
+ <span class='id identifier rubyid_file_system_command'>file_system_command</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>%q{</span><span class='tstring_content'>df -kl 2&gt;/dev/null | grep ^/ | nawk '{print $1 &quot;|&quot; $2 / 1024 &quot;|&quot; $3 / 1024 &quot;|&quot; $6}'</span><span class='tstring_end'>}</span></span>
551
+ <span class='ivar'>@connector</span><span class='period'>.</span><span class='id identifier rubyid_values_at'>values_at</span><span class='lparen'>(</span><span class='id identifier rubyid_file_system_command'>file_system_command</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_file_system'>file_system</span><span class='op'>|</span>
552
+ <span class='id identifier rubyid_h'>h</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system_template'>file_system_template</span>
553
+ <span class='id identifier rubyid_file_system'>file_system</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system'>file_system</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>|</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
554
+
555
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:capacity_mb</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system'>file_system</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span>
556
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:file_system</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system'>file_system</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span>
557
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:mount_point</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system'>file_system</span><span class='lbracket'>[</span><span class='int'>3</span><span class='rbracket'>]</span>
558
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:used_space_mb</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_file_system'>file_system</span><span class='lbracket'>[</span><span class='int'>2</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span>
559
+
560
+ <span class='ivar'>@file_systems</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_h'>h</span>
561
+ <span class='kw'>end</span>
562
+ <span class='kw'>end</span></pre>
563
+ </td>
564
+ </tr>
565
+ </table>
566
+ </div>
567
+
568
+ <div class="method_details ">
569
+ <h3 class="signature " id="get_hardware-instance_method">
570
+
571
+ - (<tt>Object</tt>) <strong>get_hardware</strong>
572
+
573
+
574
+
575
+
576
+
577
+ </h3><table class="source_code">
578
+ <tr>
579
+ <td>
580
+ <pre class="lines">
581
+
582
+
583
+ 32</pre>
584
+ </td>
585
+ <td>
586
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 32</span>
587
+
588
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_hardware'>get_hardware</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
589
+ </td>
590
+ </tr>
591
+ </table>
592
+ </div>
593
+
594
+ <div class="method_details ">
595
+ <h3 class="signature " id="get_hosted_shares-instance_method">
596
+
597
+ - (<tt>Object</tt>) <strong>get_hosted_shares</strong>
598
+
599
+
600
+
601
+
602
+
603
+ </h3><table class="source_code">
604
+ <tr>
605
+ <td>
606
+ <pre class="lines">
607
+
608
+
609
+ 33</pre>
610
+ </td>
611
+ <td>
612
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 33</span>
613
+
614
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_hosted_shares'>get_hosted_shares</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
615
+ </td>
616
+ </tr>
617
+ </table>
618
+ </div>
619
+
620
+ <div class="method_details ">
621
+ <h3 class="signature " id="get_installed_applications-instance_method">
622
+
623
+ - (<tt>Object</tt>) <strong>get_installed_applications</strong>
624
+
625
+
626
+
627
+
628
+
629
+ </h3><table class="source_code">
630
+ <tr>
631
+ <td>
632
+ <pre class="lines">
633
+
634
+
635
+ 34</pre>
636
+ </td>
637
+ <td>
638
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 34</span>
639
+
640
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_installed_applications'>get_installed_applications</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
641
+ </td>
642
+ </tr>
643
+ </table>
644
+ </div>
645
+
646
+ <div class="method_details ">
647
+ <h3 class="signature " id="get_installed_patches-instance_method">
648
+
649
+ - (<tt>Object</tt>) <strong>get_installed_patches</strong>
650
+
651
+
652
+
653
+
654
+
655
+ </h3><table class="source_code">
656
+ <tr>
657
+ <td>
658
+ <pre class="lines">
659
+
660
+
661
+ 35</pre>
662
+ </td>
663
+ <td>
664
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 35</span>
665
+
666
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_installed_patches'>get_installed_patches</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
667
+ </td>
668
+ </tr>
669
+ </table>
670
+ </div>
671
+
672
+ <div class="method_details ">
673
+ <h3 class="signature " id="get_installed_services-instance_method">
674
+
675
+ - (<tt>Object</tt>) <strong>get_installed_services</strong>
676
+
677
+
678
+
679
+
680
+
681
+ </h3><table class="source_code">
682
+ <tr>
683
+ <td>
684
+ <pre class="lines">
685
+
686
+
687
+ 36</pre>
688
+ </td>
689
+ <td>
690
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 36</span>
691
+
692
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_installed_services'>get_installed_services</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
693
+ </td>
694
+ </tr>
695
+ </table>
696
+ </div>
697
+
698
+ <div class="method_details ">
699
+ <h3 class="signature " id="get_local_user_groups-instance_method">
700
+
701
+ - (<tt>Object</tt>) <strong>get_local_user_groups</strong>
702
+
703
+
704
+
705
+
706
+
707
+ </h3><table class="source_code">
708
+ <tr>
709
+ <td>
710
+ <pre class="lines">
711
+
712
+
713
+ 38
714
+ 39
715
+ 40
716
+ 41
717
+ 42
718
+ 43
719
+ 44
720
+ 45
721
+ 46
722
+ 47
723
+ 48
724
+ 49
725
+ 50
726
+ 51
727
+ 52
728
+ 53
729
+ 54
730
+ 55
731
+ 56
732
+ 57
733
+ 58
734
+ 59
735
+ 60
736
+ 61
737
+ 62
738
+ 63
739
+ 64</pre>
740
+ </td>
741
+ <td>
742
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 38</span>
743
+
744
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_local_user_groups'>get_local_user_groups</span>
745
+ <span class='kw'>super</span>
746
+
747
+ <span class='id identifier rubyid_user_data'>user_data</span> <span class='op'>=</span> <span class='ivar'>@connector</span><span class='period'>.</span><span class='id identifier rubyid_values_at'>values_at</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>cat /etc/passwd | grep -v &quot;^#&quot;</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
748
+ <span class='id identifier rubyid_group_data'>group_data</span> <span class='op'>=</span> <span class='ivar'>@connector</span><span class='period'>.</span><span class='id identifier rubyid_values_at'>values_at</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>cat /etc/group | grep -v &quot;^#&quot;</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
749
+
750
+ <span class='id identifier rubyid_users'>users</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
751
+ <span class='id identifier rubyid_groups'>groups</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
752
+
753
+ <span class='id identifier rubyid_user_data'>user_data</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_x'>x</span><span class='op'>|</span>
754
+ <span class='id identifier rubyid_h'>h</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
755
+ <span class='id identifier rubyid_x'>x</span> <span class='op'>=</span> <span class='id identifier rubyid_x'>x</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>:</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
756
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:status</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='kw'>nil</span>
757
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:primary_group_id</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_x'>x</span><span class='lbracket'>[</span><span class='int'>3</span><span class='rbracket'>]</span>
758
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:username</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_x'>x</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span>
759
+ <span class='id identifier rubyid_users'>users</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_h'>h</span>
760
+ <span class='kw'>end</span>
761
+
762
+ <span class='id identifier rubyid_group_data'>group_data</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_group'>group</span><span class='op'>|</span>
763
+ <span class='id identifier rubyid_group'>group</span> <span class='op'>=</span> <span class='id identifier rubyid_group'>group</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>:</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
764
+ <span class='id identifier rubyid_h'>h</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='symbol'>:members</span><span class='op'>=&gt;</span><span class='lbracket'>[</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:name</span><span class='op'>=&gt;</span><span class='id identifier rubyid_group'>group</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span>
765
+
766
+ <span class='id identifier rubyid_h'>h</span><span class='lbracket'>[</span><span class='symbol'>:members</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_users'>users</span><span class='period'>.</span><span class='id identifier rubyid_select'>select</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_user'>user</span><span class='op'>|</span> <span class='lparen'>(</span><span class='id identifier rubyid_user'>user</span><span class='lbracket'>[</span><span class='symbol'>:primary_group_id</span><span class='rbracket'>]</span> <span class='op'>==</span> <span class='id identifier rubyid_group'>group</span><span class='lbracket'>[</span><span class='int'>2</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_collect'>collect</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_user'>user</span><span class='op'>|</span> <span class='id identifier rubyid_user'>user</span><span class='lbracket'>[</span><span class='symbol'>:username</span><span class='rbracket'>]</span><span class='rbrace'>}</span>
767
+
768
+ <span class='ivar'>@local_user_groups</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_h'>h</span>
769
+ <span class='kw'>end</span>
770
+ <span class='kw'>end</span></pre>
771
+ </td>
772
+ </tr>
773
+ </table>
774
+ </div>
775
+
776
+ <div class="method_details ">
777
+ <h3 class="signature " id="get_network_id-instance_method">
778
+
779
+ - (<tt>Object</tt>) <strong>get_network_id</strong>
780
+
781
+
782
+
783
+
784
+
785
+ </h3><table class="source_code">
786
+ <tr>
787
+ <td>
788
+ <pre class="lines">
789
+
790
+
791
+ 66
792
+ 67
793
+ 68
794
+ 69
795
+ 70
796
+ 71
797
+ 72
798
+ 73
799
+ 74
800
+ 75
801
+ 76
802
+ 77
803
+ 78
804
+ 79
805
+ 80</pre>
806
+ </td>
807
+ <td>
808
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 66</span>
809
+
810
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_network_id'>get_network_id</span>
811
+ <span class='kw'>super</span>
812
+
813
+ <span class='id identifier rubyid_hostname'>hostname</span> <span class='op'>=</span> <span class='ivar'>@connector</span><span class='period'>.</span><span class='id identifier rubyid_value_at'>value_at</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>hostname</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
814
+ <span class='id identifier rubyid_domain'>domain</span> <span class='op'>=</span> <span class='ivar'>@connector</span><span class='period'>.</span><span class='id identifier rubyid_value_at'>value_at</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>domainname</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
815
+ <span class='id identifier rubyid_domain'>domain</span> <span class='op'>=</span> <span class='kw'>nil</span> <span class='kw'>if</span> <span class='id identifier rubyid_domain'>domain</span> <span class='op'>=~</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>\(none\)</span><span class='regexp_end'>/i</span></span>
816
+
817
+ <span class='kw'>if</span> <span class='id identifier rubyid_hostname'>hostname</span> <span class='op'>=~</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>\.</span><span class='regexp_end'>/</span></span>
818
+ <span class='id identifier rubyid_hostname'>hostname</span> <span class='op'>=</span> <span class='id identifier rubyid_hostname'>hostname</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span>
819
+ <span class='id identifier rubyid_domain'>domain</span> <span class='op'>=</span> <span class='id identifier rubyid_hostname'>hostname</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_hostname'>hostname</span> <span class='op'>=~</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>\.</span><span class='regexp_end'>/</span></span>
820
+ <span class='kw'>end</span>
821
+
822
+ <span class='ivar'>@network_id</span><span class='lbracket'>[</span><span class='symbol'>:hostname</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_hostname'>hostname</span>
823
+ <span class='ivar'>@network_id</span><span class='lbracket'>[</span><span class='symbol'>:domain</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_domain'>domain</span>
824
+ <span class='kw'>end</span></pre>
825
+ </td>
826
+ </tr>
827
+ </table>
828
+ </div>
829
+
830
+ <div class="method_details ">
831
+ <h3 class="signature " id="get_network_interfaces-instance_method">
832
+
833
+ - (<tt>Object</tt>) <strong>get_network_interfaces</strong>
834
+
835
+
836
+
837
+
838
+
839
+ </h3><table class="source_code">
840
+ <tr>
841
+ <td>
842
+ <pre class="lines">
843
+
844
+
845
+ 82</pre>
846
+ </td>
847
+ <td>
848
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 82</span>
849
+
850
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_network_interfaces'>get_network_interfaces</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
851
+ </td>
852
+ </tr>
853
+ </table>
854
+ </div>
855
+
856
+ <div class="method_details ">
857
+ <h3 class="signature " id="get_operating_system-instance_method">
858
+
859
+ - (<tt>Object</tt>) <strong>get_operating_system</strong>
860
+
861
+
862
+
863
+
864
+
865
+ </h3><table class="source_code">
866
+ <tr>
867
+ <td>
868
+ <pre class="lines">
869
+
870
+
871
+ 83</pre>
872
+ </td>
873
+ <td>
874
+ <pre class="code"><span class="info file"># File 'lib/boris/profiles/unix_core.rb', line 83</span>
875
+
876
+ <span class='kw'>def</span> <span class='id identifier rubyid_get_operating_system'>get_operating_system</span><span class='semicolon'>;</span> <span class='kw'>super</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
877
+ </td>
878
+ </tr>
879
+ </table>
880
+ </div>
881
+
882
+ </div>
883
+
884
+ </div>
885
+
886
+ <div id="footer">
887
+ Generated on Sun Feb 3 16:32:41 2013 by
888
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
889
+ 0.8.3 (ruby-1.9.3).
890
+ </div>
891
+
892
+ </body>
893
+ </html>