Could you please tell me which of the solutions worked in this case As i am also trying to do the same I am trying to do it with concat like this for /etc/profile file editing
class postgresql::profilechange{ include concat::setup concat { '/etc/profile': mode => '0775', owner => 'root', group => 'root', ensure => present, } concat::fragment { 'file04_fa': target => '/etc/profile', content => "PATH=$PATH:/usr/local/pgsql/bin\n", order => 01 } } But it is giving me this error --------------------------------------------------- Info: Retrieving plugin Info: Loading facts in /etc/puppet/modules/stdlib/lib/facter/puppet_vardir.rb Info: Loading facts in /etc/puppet/modules/stdlib/lib/facter/facter_dot_d.rb Info: Loading facts in /etc/puppet/modules/stdlib/lib/facter/root_home.rb Info: Loading facts in /etc/puppet/modules/stdlib/lib/facter/pe_version.rb Info: Loading facts in /etc/puppet/modules/concat/lib/facter/concat_basedir.rb Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find class concat::setup for sys-server on node sys-server Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run Any pointers are appreciated On Tuesday, August 12, 2014 at 10:19:47 PM UTC+5:30, Sijis Aviles wrote: > > > > On Tuesday, August 12, 2014 1:57:14 AM UTC-5, Vikas Kumar wrote: >> >> Hello, >> >> I am looking for an option to add multiple lines to a */etc/bashrc* and >> */etc/profile*. I can do this with *file_line*, but is there any other >> alternative. *file_line* does the job but for each line I will have to >> create a *file_line* resource, which does not sound good for multiple >> lines. >> >> Regards, >> Vikas >> > > Vikas, > > Maybe try using concat module ( > https://github.com/puppetlabs/puppetlabs-concat)? But i think you'll > still have multiple concat::fragment entries. > > Sijis > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/f950c7b9-e200-43b6-ba04-6784b21316d2%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.