I expanded the scope of an old in-house puppet manifest for utilities installation to apply it to more servers, and ran into:
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Function Call, Duplicate declaration: Package[wget] is already declared at (file: /etc/puppetlabs/code/environments/production/site/packages/manifests/wget.pp, line: 2); cannot redeclare (file: /etc/puppetlabs/code/environments/production/modules/foreman_proxy/manifests/tftp.pp, line: 47) (file: /etc/puppetlabs/code/environments/production/modules/foreman_proxy/manifests/tftp.pp, line: 47, column: 5) on node my-foreman-proxy.example.com
I fixed this by correcting the old in-house puppet manifest to use the preferred form, stdlib::ensure_packages(['wget']) rather than directly declaring the package resource.
It would be nice if this could be fixed within the foreman installer puppet modules as well.
I expanded the scope of an old in-house puppet manifest for utilities installation to apply it to more servers, and ran into:
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Function Call, Duplicate declaration: Package[wget] is already declared at (file: /etc/puppetlabs/code/environments/production/site/packages/manifests/wget.pp, line: 2); cannot redeclare (file: /etc/puppetlabs/code/environments/production/modules/foreman_proxy/manifests/tftp.pp, line: 47) (file: /etc/puppetlabs/code/environments/production/modules/foreman_proxy/manifests/tftp.pp, line: 47, column: 5) on node my-foreman-proxy.example.com
I fixed this by correcting the old in-house puppet manifest to use the preferred form,
stdlib::ensure_packages(['wget'])
rather than directly declaring the package resource.It would be nice if this could be fixed within the foreman installer puppet modules as well.