我在踢 -mode(puppetrun)中使用Puppet:
客户端的puppet.conf:
[main]
modulepath = /etc/puppet/modules:/usr/share/puppet/modules
logdir = /var/log/puppet
rundir = /var/run/puppet
# The default value is '$confdir/ssl'.
ssldir = $vardir/ssl
server = puppetmaster.example.com
listen = true
# only kick, no polling
client = false
certname = client.example.com
pluginsync = true
[agent]
# The default value is '$confdir/classes.txt'.
classfile = $vardir/classes.txt
ignorecache = true
report = true
environment = dev
client = false
# The default value is '/localconfig'.
localconfig = $vardir/localconfig
* puppet kick --host * 效果很好,但是每隔30(runinterval)分钟,puppet客户端会自行触发部署(轮询)。
我认为 client = false 会停止投票,但似乎没有。
有人知道解决这个问题的方法吗?
感谢慕尼黑, 岸堤
答案 0 :(得分:2)
据说,似乎puppet.conf中的client = false
指令不存在
http://docs.puppetlabs.com/references/stable/configuration.html(虽然是最重要的
页面指定它应该可用。)
启动代理时可以指定--no-client
选项(使用puppet help agent
检查):
--no-client:
Do not create a config client. This will cause the daemon to run
without ever checking for its configuration automatically, and only
makes sense when puppet agent is being run with listen = true in puppet.conf
or was started with the `--listen` option.
添加这些内容的最佳位置是/etc/sysconfig/puppet
用于基于RPM的GNU / Linux发行版,/etc/default/puppet
用于基于deb的发行版。
对于其他人,您必须检查启动脚本。
答案 1 :(得分:0)
看起来你想在[main]部分中'onetime = true'。它看起来不像是客户端设置。见http://docs.puppetlabs.com/references/stable/configuration.html#onetime