{"id":164923,"date":"2013-01-06T21:21:05","date_gmt":"2013-01-06T17:21:05","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=164923"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=164923","title":{"rendered":"<span class=\"post_title\">Cfengine3 \u2014 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043e policy hub<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t\u0412 <a href=\"http:\/\/habrahabr.ru\/post\/164445\/\">\u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u0437\u0430\u043c\u0435\u0442\u043a\u0435<\/a> \u044f \u043a\u0440\u0430\u0442\u043a\u043e \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u043b \u043e \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044f\u043c\u0438 cfengine3. \u0421\u0435\u0433\u043e\u0434\u043d\u044f \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0435\u0435 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043a\u0430\u0441\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043b\u0438\u0435\u043d\u0442-\u0441\u0435\u0440\u0432\u0435\u0440\u043d\u043e\u0439 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438 \u0431\u043e\u043b\u0435\u0435 \u0442\u043e\u043d\u043a\u043e\u0439 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u043c\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438.<\/p>\n<p>  <a name=\"habracut\"><\/a><\/p>\n<p>  \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c cfengine3 \u043f\u0430\u043a\u0435\u0442, \u043a\u0430\u043a \u0438 \u0432 \u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u0437\u0430\u043c\u0435\u0442\u0435, \u043a\u0430\u043a \u043d\u0430 \u043a\u043b\u0438\u0435\u043d\u0442\u0435 \u0442\u0430\u043a \u0438 \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435 \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0438 (policy hub). \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043b\u0438\u0435\u043d\u0442-\u0441\u0435\u0440\u0432\u0435\u0440\u043d\u0443\u044e cfengine3 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e. \u041f\u043e\u043b\u043e\u0436\u0438\u043c: policyhub01 198.51.100.10, srv01.local 203.0.113.101. \u0418\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u0441\u0435\u0431\u044f \u043a\u0430\u043a policy hub (198.51.100.10 \u043d\u0430\u0448 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 IP). \u041f\u043e\u043b\u0438\u0441\u0438 \u0445\u0430\u0431, \u043a\u0430\u043a \u0440\u0430\u0437 \u0438 \u0435\u0441\u0442\u044c \u0442\u043e \u043c\u0435\u0441\u0442\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441\u043b\u0443\u0436\u0438\u0442 \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435\u043c \u043d\u0430\u0448\u0438\u0445 \u043f\u043e\u043b\u0438\u0442\u0438\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u0437\u0434\u043d\u0435\u0435 \u0431\u0443\u0434\u0443\u0442 \u0441\u043a\u0430\u0447\u0430\u043d\u044b \u0441 \u043d\u0435\u0433\u043e \u043a\u043b\u0438\u0435\u043d\u0442\u0430\u043c\u0438. \u041f\u043e\u0447\u0442\u0438 \u0432\u0441\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u043c\u0435\u043d\u0435\u0434\u0436\u043c\u0435\u043d\u0442\u0430 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0439 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 pull, \u0430 \u043d\u0435 push, \u0442\u043e\u043c\u0443 \u0435\u0441\u0442\u044c \u043c\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u0447\u0438\u043d, \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u0435 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0437\u0430\u0439\u043c\u0435\u0442 \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 \u0447\u0435\u043c \u043e\u0431\u044a\u0435\u043c \u044d\u0442\u043e\u0439 \u0437\u0430\u043c\u0435\u0442\u043a\u0438.<br \/>  <b>root@policyhub01:\/tmp# \/var\/cfengine\/bin\/cf-agent &#8212;bootstrap &#8212;policy-server=198.51.100.10<\/b>  <\/p>\n<pre><code class=\"bash\">** CFEngine BOOTSTRAP probe initiated     @@@          @@@      CFEngine               @ @@@ @    CFEngine Core 3.4.1  @ @@@ @      @ @@@ @      @     @        @@@          @ @          @ @          @ @        Copyright (C) CFEngine AS 2008-2012 See Licensing at http:\/\/cfengine.com\/3rdpartylicenses   -&gt; This host is: policyhub01.local  -&gt; Operating System Type is linux  -&gt; Operating System Release is 3.6.10-vs2.3.4.6  -&gt; Architecture = x86_64  -&gt; Internal soft-class is linux  -&gt; No policy failsafe discovered, assume temporary bootstrap vector  -&gt; No previous policy has been cached on this host  -&gt; Assuming the policy distribution point at: 198.51.100.10:\/var\/cfengine\/masterfiles  -&gt; Attempting to initiate promised autonomous services...   ** This host recognizes itself as a CFEngine Policy Hub, with policy distribution and knowledge base.  -&gt; The system is now converging. Full initialisation and self-analysis could take up to 30 minutes  R: This host assumes the role of policy distribution host R:  -&gt; Updated local policy from policy server R:  -&gt; Started the server R:  -&gt; Started the scheduler -&gt; Bootstrap to 198.51.100.10 completed successfully <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043a\u043b\u0438\u0435\u043d\u0442\u0443:<br \/>  <b>root@srv01:\/tmp# \/var\/cfengine\/bin\/cf-agent &#8212;bootstrap &#8212;policy-server=198.51.100.10<\/b>   <\/p>\n<pre><code class=\"bash\">-&gt; No policy failsafe discovered, assume temporary bootstrap vector  -&gt; No previous policy has been cached on this host  -&gt; Assuming the policy distribution point at: 198.51.100.10:\/var\/cfengine\/masterfiles  -&gt; Attempting to initiate promised autonomous services...  Challenge response from server 198.51.100.10\/198.51.100.10 was incorrect!  !! Authentication dialogue with 198.51.100.10 failed R: This autonomous node assumes the role of voluntary client R:  !! Failed to pull policy from policy server R:  !! Did not start the scheduler !! Bootstrapping failed, no input file at \/var\/cfengine\/inputs\/promises.cf after bootstrap  \u0427\u0430\u0441\u0442\u044c \u0432\u044b\u0432\u043e\u0434\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u0430. <\/code><\/pre>\n<p>  \u041d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442! \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e cfengine3 \u0434\u043e\u0432\u0435\u0440\u044f\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0445\u043e\u0441\u0442\u0430\u043c \u0438\u0437 \u0441\u0432\u043e\u0435\u0439 \/16, \u0430 \u0443 \u043d\u0430\u0441 \u0441\u0435\u0440\u0432\u0435\u0440 \u0438 \u043a\u043b\u0438\u0435\u043d\u0442 \u0432 \u0440\u0430\u0437\u043d\u044b\u0445 \u0441\u0435\u0442\u044f\u0445. \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e \u044d\u0442\u043e \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u0448\u0438\u0440\u043e\u043a\u0438\u0439 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0438 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0435\u0433\u043e \u0441\u0440\u0430\u0437\u0443 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0442\u044c \u0432 \u0444\u0430\u0439\u043b\u0430\u0445 <b>\/var\/cfengine\/inputs\/def.cf<\/b> \u0438 <b>\/var\/cfengine\/inputs\/controls\/cf_serverd.cf<\/b>.<br \/>  \u0418\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c \u043d\u0430 plicyhub01 \u0444\u0430\u0439\u043b<b> \/var\/cfengine\/inputs\/def.cf <\/b>  <\/p>\n<pre><code class=\"bash\">    &quot;acl&quot; slist =&gt; {                    &quot;$(sys.policy_hub)&quot;,                 &quot;203.0.113.101\/32&quot;,                    }, <\/code><\/pre>\n<p>  \u041c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0431\u044b (\u0438 \u0438\u0434\u0435\u043e\u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u0435\u0435 ?) \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043e\u0431\u043c\u0435\u043d \u043a\u043b\u044e\u0447\u0430\u043c\u0438 \u0438\u043d\u044b\u043c<br \/>  \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c, \u043d\u0435 \u0436\u0435 \u043b\u0438 \u0434\u0435\u043b\u0430\u0442\u044c &#8216;trust&#8217; \u043f\u043e IP. \u0412\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043d\u0430 srv01 \u043e\u043f\u044f\u0442\u044c: <b>root@srv01:\/tmp# \/var\/cfengine\/bin\/cf-agent &#8212;bootstrap &#8212;policy-server=198.51.100.10<\/b>  <\/p>\n<pre><code class=\"bash\">** CFEngine BOOTSTRAP probe initiated     @@@          @@@      CFEngine               @ @@@ @    CFEngine Core 3.4.1  @ @@@ @      @ @@@ @      @     @        @@@          @ @          @ @          @ @        Copyright (C) CFEngine AS 2008-2012 See Licensing at http:\/\/cfengine.com\/3rdpartylicenses   -&gt; This host is: srv01.local  -&gt; Operating System Type is linux  -&gt; Operating System Release is 3.6.10-vs2.3.4.6  -&gt; Architecture = x86_64  -&gt; Internal soft-class is linux  -&gt; An existing policy was cached on this host in \/var\/cfengine\/inputs  -&gt; Assuming the policy distribution point at: 198.51.100.10:\/var\/cfengine\/masterfiles  -&gt; Attempting to initiate promised autonomous services...  R: This autonomous node assumes the role of voluntary client -&gt; Bootstrap to 198.51.100.10 completed successfully <\/code><\/pre>\n<p>  \u0423\u0441\u043f\u0435\u0445! \u0422\u0435\u043f\u0435\u0440\u044c \u0441\u0430\u043c\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u043b\u0438\u0442\u0438\u043a \u043d\u0430 \u0441\u0442\u043e\u0440\u043e\u043d\u0435 policyhub01 \u0438 \u0443\u0431\u0435\u0434\u0438\u0442\u0441\u044f \u0447\u0442\u043e \u0432\u0441\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<br \/>  \u041d\u0430 <b>policyhub01<\/b> \u0432 <b>\/var\/cfengine\/masterfiles<\/b> \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b\u044b <br \/>  config_web_srv.cf:<\/p>\n<pre><code class=\"bash\">bundle agent config_web_srv {  vars:   &quot;package_list&quot; slist =&gt; { &quot;nginx&quot; };   packages:   &quot;${package_list}&quot;   package_policy =&gt; &quot;add&quot;,   package_method =&gt; generic;   processes:    &quot;nginx&quot;          restart_class =&gt; &quot;start_nginx&quot;;  commands:     &quot;\/etc\/init.d\/nginx restart&quot;        ifvarclass =&gt; canonify(&quot;start_nginx&quot;);  } <\/code><\/pre>\n<p>  \u0438 install_base_pkg.cf:  <\/p>\n<pre><code class=\"bash\">bundle agent install_base_pkg {  vars:   &quot;package_list&quot; slist =&gt; { &quot;vim&quot;, &quot;mc&quot; };   packages:   &quot;${package_list}&quot;   package_policy =&gt; &quot;add&quot;,   package_method =&gt; generic;    files:   linux::    &quot;\/etc\/motd&quot;    edit_line     =&gt; insert_lines(&quot;This host is managed by cfengine3!&quot;); } <\/code><\/pre>\n<p>  \u0412\u0430\u0436\u043d\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u0438 \u0444\u0430\u0439\u043b\u044b \u0442\u0430\u043a \u0436\u0435 \u0432 inputs: <b>root@policyhub01:\/var\/cfengine\/masterfiles# cp config_web_srv.cf install_base_pkg.cf ..\/inputs\/<\/b>. \u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u0441\u0442\u0430\u043b\u043e \u0432\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u0442\u043e \u0436\u0435 \u0438\u0437 \u0445\u043e\u0441\u0442\u043e\u0432 \u0434\u043e\u043b\u0436\u0435\u043d \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u044d\u0442\u0438 \u043f\u043e\u043b\u0438\u0441\u0438. \u0412 \u0444\u0430\u0439\u043b\u0435 <b>\/var\/cfengine\/masterfiles\/promises.cf<\/b> \u043d\u0430\u0445\u043e\u0434\u0438\u043c body control inputs \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0442\u0443\u0434\u0430 \u043d\u0430\u0448\u0438 \u0444\u0430\u0439\u043b\u044b:<\/p>\n<pre><code class=\"bash\">inputs =&gt; {           # Global common bundles             &quot;def.cf&quot;,           # Control body for all agents             &quot;controls\/cf_agent.cf&quot;,             &quot;controls\/cf_execd.cf&quot;,             &quot;controls\/cf_monitord.cf&quot;,             &quot;controls\/cf_report.cf&quot;,             &quot;controls\/cf_runagent.cf&quot;,             &quot;controls\/cf_serverd.cf&quot;,           # COPBL\/Custom libraries             &quot;libraries\/cfengine_stdlib.cf&quot;,           # Design Center              # MARKER FOR CF-SKETCH INPUT INSERTION              &quot;cf-sketch-runfile.cf&quot;,           # User services from here             &quot;services\/init_msg.cf&quot;,           # our policies             &quot;config_web_srv.cf&quot;,             &quot;install_base_pkg.cf&quot;,              }; <\/code><\/pre>\n<p>  \u0414\u0430\u043b\u0435\u0435, \u0432 \u044d\u0442\u043e\u043c \u0436\u0435 \u0444\u0430\u0439\u043b\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u043d\u0430\u0448 \u0431\u0430\u043d\u0434\u043b:<\/p>\n<pre><code class=\"bash\">bundle agent config {  classes:     &quot;web_srv&quot;    or =&gt; { classmatch(&quot;web.*&quot;),                          &quot;srv01_local&quot;,                          &quot;web3_example_com&quot;                        };  methods:     web_srv::         &quot;config_web_srv&quot; usebundle =&gt; &quot;config_web_srv&quot;;     any::         &quot;install_everywhere&quot; usebundle =&gt; &quot;install_base_pkg&quot;;   reports:   cfengine_3::     &quot;bundle agent config DONE&quot;;  } <\/code><\/pre>\n<p>  \u0418 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0435\u0433\u043e \u0432 bundlesequence:  <\/p>\n<pre><code class=\"bash\"> bundlesequence =&gt; {                   # Common bundles first for best practice                     &quot;def&quot;,                   # Design Center                     &quot;cfsketch_run&quot;,                   # Agent buddles from here                     &quot;main&quot;,                   # Our ccustomisation                     &quot;config&quot;,                     };  <\/code><\/pre>\n<p>  \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c \u0438 \u0436\u0434\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e 5 \u043c\u0438\u043d\u0443\u0442. \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0438 \u0443\u0434\u043e\u0441\u0442\u043e\u0432\u0435\u0440\u044f\u0435\u043c\u0441\u044f, \u0447\u0442\u043e \u043f\u0430\u043a\u0435\u0442\u044b \u0438\u0437 install_base_pkg \u0438 config_web_srv \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u044b. \u0420\u0430\u0437\u0431\u0435\u0440\u0435\u043c, \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u043e\u0448\u043b\u043e. \u041a\u043b\u0438\u0435\u043d\u0442, \u043a\u0430\u043a \u0438 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043e, \u0441\u043a\u0430\u0447\u0430\u043b \u0441\u0435\u0431\u0435 \u0432 inputs \u0444\u0430\u0439\u043b\u044b \u0438\u0437 masterfiles \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u043e\u043b\u0438\u0441\u0438 \u0445\u0430\u0431\u0430. \u0414\u0430\u043b\u0435\u0435 cf-agen \u043d\u0430 \u0441\u0442\u043e\u0440\u043e\u043d\u0435 srv01 \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442 \u0438\u0445 \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c, \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0432 \u0445\u0430\u0440\u0434 \u043a\u043b\u0430\u0441\u0441\u044b:  <\/p>\n<pre><code class=\"bash\">Hard classes = { 203_0_113_101 2_cpus 64_bit Afternoon Day6 GMT_Hr17 Hr17 Hr17_Q2 January Lcycle_0 Min20_25 Min21 PK_MD5_877dfa1640c3c49a2065ce220a3b821f Q2 Sunday Yr2013 agent any cfengine cfengine_3 cfengine_3_4 cfengine_3_4_1 cfengine_in_high community_edition compiled_on_linux_gnu cpu0_normal cpu1_normal cpu_normal debian debian_7 debian_7_0 diskfree_high_normal entropy_misc_in_low entropy_misc_out_low entropy_postgresql_in_low entropy_postgresql_out_low have_aptitude ipv4_203 ipv4_203_0 ipv4_203_0_113 ipv4_203_0_113_101 linux linux_3_6_10_vs2_3_4_6 linux_x86_64 linux_x86_64_3_6_10_vs2_3_4_6 linux_x86_64_3_6_10_vs2_3_4_6__1_SMP_Mon_Dec_17_03_23_11_UTC_2012 local mac_00_25_64_3b_97_cb messages_high_ldt messages_high_normal net_iface_br0 opt_dry_run otherprocs_low rootprocs_high rootprocs_high_ldt srv01 srv01_local syslog_high_ldt syslog_high_normal users_low verbose_mode www_in_low x86_64 } <\/code><\/pre>\n<p>  \u0421\u043f\u0438\u0441\u043e\u043a \u0445\u0430\u0440\u0434 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u043d\u0430 \u0434\u0430\u043d\u043d\u043e\u043c \u0445\u043e\u0441\u0442\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0432 <b>cf-agent -v<\/b>. \u0412\u044b\u0448\u0435 \u043c\u044b \u0441\u043a\u0430\u0437\u0430\u043b\u0438 bundlesequence \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043d\u0430\u0448 \u0431\u0430\u043d\u0434\u043b &#8216;config&#8217;. \u041f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c \u043c\u044b \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c soft \u043a\u043b\u0430\u0441\u0441\u044b \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0438\u043c\u0435\u044e\u0449\u0438\u0445\u0441\u044f hard \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u0412 \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0430\u0448\u0435\u0433\u043e srv01 \u0431\u0443\u0434\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d soft \u043a\u043b\u0430\u0441\u0441 web_srv, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u043f\u043e \u043a\u043b\u0430\u0441\u0441\u0443 \u0434\u043e\u043c\u0435\u043d\u043d\u043e\u0433\u043e \u0438\u043c\u0435\u043d\u0438. \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0441\u0435\u043a\u0446\u0438\u044f methods \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442 \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0438 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d \u043d\u0443\u0436\u043d\u044b\u0439 bundle. \u0411\u0430\u043d\u0434\u043b install_base_pkg \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0445\u043e\u0441\u0442\u043e\u0432, \u0442\u0430\u043a \u043a\u0430\u043a hard \u043a\u043b\u0430\u0441\u0441 any \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d \u0432\u0441\u0435\u0433\u0434\u0430. \u0414\u043b\u044f \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0438 install_base_pkg \u0438 config_web_srv, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442 \u043f\u0430\u043a\u0435\u0442 nginx \u0438 \u043f\u0435\u0440\u0438\u043e\u0434\u0438\u0447\u0435\u0441\u043a\u0438 \u0431\u0443\u0434\u0435\u0442 \u0443\u0434\u043e\u0441\u0442\u043e\u0432\u0435\u0440\u044f\u0442\u0441\u044f \u0447\u0442\u043e \u043e\u043d \u0437\u0430\u043f\u0443\u0449\u0435\u043d. \u042d\u0442\u0438\u043c \u043a\u0430\u043a \u0440\u0430\u0437 \u0438 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442\u0441\u044f \u043a\u043b\u0430\u0441\u0441 nginx \u0442\u0438\u043f\u0430 proccess, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442 soft \u043a\u043b\u0430\u0441\u0441 \u00abstart_nginx\u00bb \u0435\u0441\u043b\u0438 \u0442\u0430\u043a\u043e\u0433\u043e \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u043d\u0435\u0442, \u0447\u0442\u043e \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u0442 \u043a \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b &quot;\/etc\/init.d\/nginx restart&quot;. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0438\u043b\u0438 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c nginx, \u043d\u043e cfengine \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0435\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442 \u0447\u0435\u0440\u0435\u0437 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f! <\/p>\n<p>  \u041d\u0430 \u044d\u0442\u043e\u043c \u0432\u0441\u0435, \u043d\u0430\u0434\u0435\u044e\u0441\u044c \u044d\u0442\u0430 \u0437\u0430\u043c\u0435\u0442\u043a\u0430 \u043f\u0440\u043e\u044f\u0441\u043d\u0438\u043b\u0430 \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u0435\u0440\u0435 \u0432\u043e\u043f\u0440\u043e\u0441 \u00absolo\u00bb \u0438 \u00ab\u043a\u043b\u0438\u0435\u043d-\u0441\u0435\u0440\u0432\u0435\u0440\u00bb \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438. \u041a\u0430\u043a \u0432\u0441\u0435\u0433\u0434\u0430, \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u0441\u0430\u0439\u0442, \u0438 \u0432 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438, \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0432\u0441\u0435\u0433\u0434\u0430 \u043f\u0440\u0438\u0434\u0443\u0442 \u043d\u0430 \u043f\u043e\u043c\u043e\u0449\u044c!<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/164923\/\"> http:\/\/habrahabr.ru\/post\/164923\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t\u0412 <a href=\"http:\/\/habrahabr.ru\/post\/164445\/\">\u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u0437\u0430\u043c\u0435\u0442\u043a\u0435<\/a> \u044f \u043a\u0440\u0430\u0442\u043a\u043e \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u043b \u043e \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044f\u043c\u0438 cfengine3. \u0421\u0435\u0433\u043e\u0434\u043d\u044f \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0435\u0435 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043a\u0430\u0441\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043a\u043b\u0438\u0435\u043d\u0442-\u0441\u0435\u0440\u0432\u0435\u0440\u043d\u043e\u0439 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438 \u0431\u043e\u043b\u0435\u0435 \u0442\u043e\u043d\u043a\u043e\u0439 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u043c\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-164923","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/164923","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=164923"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/164923\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=164923"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=164923"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=164923"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}