官术网_书友最值得收藏!

Dry testing your manifest

Another useful command-line switch for puppet apply is the --noop option.
It instructs Puppet to refrain from taking any action on unsynced resources.
Instead, you only get a log output that indicates what will change without the switch. This is useful in determining whether a manifest would possibly break anything on your system:

root@puppetmaster:~# puppet apply puppet_service.pp --noop
Notice: Compiled catalog for puppetmaster.example.net in environment production in 0.63 seconds
Notice: /Stage[main]/Main/Service[puppet]/enable: current_value true, should be false (noop)
Notice: Class[Main]: Would have triggered 'refresh' from 1 events
Notice: Stage[main]: Would have triggered 'refresh' from 1 events
Notice: Applied catalog in 0.06 seconds
The output format is the same as before, with a ( noop) marker trailing the notice about the sync action. This log can be considered a preview of what will happen when the manifest is applied without the --noop switch.

The additional notices about triggered refreshes will be described later, and can be ignored for the moment. You will have a better understanding of their significance after finishing this chapter and Chapter 4, Combining Resources in Classes and Defined Types.

主站蜘蛛池模板: 花垣县| 洪江市| 出国| 阳江市| 绥宁县| 永善县| 柯坪县| 历史| 泰州市| 鄱阳县| 河北省| 独山县| 贺州市| 河源市| 静海县| 泗水县| 林口县| 双柏县| 浙江省| 怀集县| 安庆市| 定州市| 高州市| 顺义区| 安化县| 张家口市| 班戈县| 尼玛县| 科技| 莱州市| 万源市| 原平市| 陆川县| 嘉定区| 正宁县| 乌拉特后旗| 卓尼县| 二手房| 马关县| 麦盖提县| 平昌县|