Я получаю следующую ошибку, используя puppet
модуль на моем мастере Puppet для управления как мастером (Apache / Passenger), так и агентом
[ashinn@puppet1 ~]$ sudo puppet agent --test
Info: Retrieving plugin
Info: Loading facts in /var/lib/puppet/lib/facter/os_maj_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
Info: Loading facts in /var/lib/puppet/lib/facter/ip6tables_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/concat_basedir.rb
Info: Loading facts in /var/lib/puppet/lib/facter/iptables_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Must pass puppet_server to Class[Puppet::Agent] at /etc/puppet/environments/production/modules/puppet/manifests/init.pp:181 on node puppet1.mydomain.com
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
Определение узла для puppet1.mydomain.com
довольно просто:
node 'puppet1.mydomain.com' {
include motd
include ntp
class { 'puppet' :
puppet_server => 'puppet.mydomain.com',
version => 'latest',
master => true,
agent => true,
autosign => '$confdir/autosign.conf',
manifest => '$confdir/environments/$environment/manifests/site.pp',
modulepath => '$confdir/environments/$environment/modules',
puppet_passenger => true,
}
}
Конкретный модуль и init.pp
находятся в https://github.com/olindata/puppetlabs-puppet/blob/master/manifests/init.pp. Строка 181 содержит закрывающую }
для оператора 'class {puppet :: master: `.
Я вижу, что init.pp
действительно проходит puppet_server
к puppet::agent
класс:
if $agent {
class {'puppet::agent':
version => $version,
puppet_defaults => $puppet_defaults,
puppet_agent_service => $puppet_agent_service,
puppet_server => $puppet_server,
environment => $environment,
puppet_conf => $puppet_conf,
puppet_agent_name => $puppet_agent_name,
package_provider => $package_provider,
reporting => $reporting,
user_id => $user_id,
group_id => $group_id,
}
}
Что могло быть не так? Я упустил что-то очевидное?