Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

I am constantly getting syntax error in site.pp while trying to use parametrized class for passing values.

$
0
0
. root@master:/etc/puppet/manifests# cat site.pp class base { include ssh } node 'agent.thomsonreuters.com' { class { 'phase60': $mode => 'standalone', $release => 'v4', } } node 'agent2.thomsonreuters.com' { include base } node 'agent3.thomsonreuters.com' { include phase60 } root@master:/etc/puppet/manifests# Iam running the "puppet agent -t" in the agent.thomsonreuters.com and i get below error root@agent:/# puppet agent -t Info: Retrieving pluginfacts Info: Retrieving plugin Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not parse for environment production: Syntax error at 'mode'; expected '}' at /etc/puppet/manifests/site.pp:7 on node agent.thomsonreuters.com Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run root@agent:/# The below is my init.pp file root@master:/etc/puppet/modules/phase60/manifests# cat init.pp class phase60 ($mode,$release) { if ! ($mode in ['standalone', 'rac']) { fail('lion mode parameter must be standalone or rac') } if ! ($release in ['v1', 'v2', 'v3', 'v4']) { fail('lion release parameter must be v1, v2, v3, or v4') } include phase60::os_package include phase60::swap_memory include phase60::users } root@master:/etc/puppet/modules/phase60/manifests# Any help would be much appreciated.

Viewing all articles
Browse latest Browse all 6104

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>