人偶环境

Puppet Environments

如何在 puppet 企业版 5.5.2 中将默认生产环境更改为开发环境。

我尝试了 soem 步骤,但出现 "Local environment: 'DEV' doesn't match server specified node environment 'production', switching agent to 'production'" 错误。

我不确定您可以在 PE 的控制面板中的哪个位置设置它,但我希望它在某个地方。但是,如果您愿意并且能够修改 Puppet 的配置文件,那么您需要修改 environment 属性,为此,您应该将其设置在 [master]部分。它在其他部分有不同的含义,所以不要全局设置。当然,因此 on master 你需要设置它。

这是我 运行 在代理上更改环境的命令:
puppet config set --section agent environment development
在 Linux,您可以在以下位置看到此更改:
/etc/puppetlabs/puppet/puppet.conf
你应该看到这样的东西:
...
[agent]
environment = development

Specifying in /etc/puppetlabs/puppet.conf
[agent]
environment = dev
report = true
pluginsync = true
runinterval=31557600

In master console (after creating group)
go to Rules Tab.In fact select agent specified environment and give the name of the environment as dev.Nodes which matches the environment will dynamically added to the group.