unable to copy file with source attribute
I have written test manifest for source attribute, below is the one
file { '/tmp/testfile/testsource':
ensure => present,
source => '/tmp/copyfile/aa'
}
aa is the file that I wanna copy it to /testsource file location, both ( /tmp/testfile/testsource and /tmp/copyfile/aa) are present in agent.
testsource file is created but unable to copy aa file to /tmp/testfile/testsource location.
I am not sure, what blunder I did.
Could someone help me.
Copy the `file {…}` resource above into a temporary file on the agent node, then, as root, run `puppet apply --test /path/to/temporary/file.pp` and add the results to your question?
yes I wrote below manifests testfile.pp class testfile { file { '/tmp/testfile/testsource': ensure => present, source => '/tmp/copyfile/aa' } include tesfile and ran "puppet agent -t /etc/puppetlabs/puppet/modules/tesfile.pp" but I didn't get any o/p
Run puppet apply --test /etc/puppetlabs/puppet/modules/testfile.pp -- apply, not agent.
"Notice: Compiled catalog for server.puppet.com in environment production in 0.18 seconds Info: Applying configuration version '1431920048' Notice: Finished catalog run in 0.82 seconds" This is the message I got it
wait - is /tmp/testfile/testsource a directory or a file?