Hi, Please correct me if I''m wrong but it seems to me that in the case of a remote file source the path must contain the plain filename after the module and paths with directory elements are not supported. What I wanted is the following: +++++ fileserver.conf +++++ [system] path /services/puppet/common/ allow * +++++ site.pp +++++++++++++ file { "/etc/local/sysctl": owner => root, group => root, mode => 750, source => "puppet://puppet/system/$name" } and get "/etc/local/systctl" from "/services/puppet/common/etc/local/sysctl" on the server. But instead of it, strangely enough an empty /etc/local/systctl directory were created on the client machine. Is it a feature or a misconfiguration on my part? Best regards, Jozsef -- E-mail : kadlec@sunserv.kfki.hu, kadlec@blackhole.kfki.hu PGP key: http://www.kfki.hu/~kadlec/pgp_public_key.txt Address: KFKI Research Institute for Particle and Nuclear Physics H-1525 Budapest 114, POB. 49, Hungary
On Jan 10, 2007, at 4:59 AM, Kadlecsik Jozsi wrote:> Hi, > > Please correct me if I''m wrong but it seems to me that in the case > of a > remote file source the path must contain the plain filename after the > module and paths with directory elements are not supported. > > What I wanted is the following: > > +++++ fileserver.conf +++++ > [system] > path /services/puppet/common/ > allow * > > +++++ site.pp +++++++++++++ > file { "/etc/local/sysctl": > owner => root, > group => root, > mode => 750, > source => "puppet://puppet/system/$name" > } > > and get "/etc/local/systctl" from > "/services/puppet/common/etc/local/sysctl" on the server. But > instead of > it, strangely enough an empty /etc/local/systctl directory were > created on > the client machine. > > Is it a feature or a misconfiguration on my part?A slight misconfiguration -- you need to add ''recurse => true'' to your file configuration. -- SELF-EVIDENT, adj. Evident to one''s self and to nobody else. -- Ambrose Bierce --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com
Hi, On Wed, 10 Jan 2007, Luke Kanies wrote:> > What I wanted is the following: > > > > +++++ fileserver.conf +++++ > > [system] > > path /services/puppet/common/ > > allow * > > > > +++++ site.pp +++++++++++++ > > file { "/etc/local/sysctl": > > owner => root, > > group => root, > > mode => 750, > > source => "puppet://puppet/system/$name" > > } > > > > and get "/etc/local/systctl" from > > "/services/puppet/common/etc/local/sysctl" on the server. > > A slight misconfiguration -- you need to add ''recurse => true'' to > your file configuration.Adding ''recurse => true'' does not help. The logged messages in verbose mode on the server: info: Starting server for Puppet version 0.22.0 info: /services/puppet/common: allowing * access info: Parsed manifest in 0.01 seconds info: Listening on port 8140 notice: Starting Puppet server version 0.22.0 Warning: cannot open /proc/net/dev (Permission denied). Limited output. notice: Compiled configuration for blue1.kfki.hu in 0.00 seconds info: /services/puppet/common: Sending /system/etc/local/sysctl.conf to blue1.kfki.hu info: /services/puppet/common: Sending /system/etc/local/sysctl to blue1.kfki.hu and on the client info: Caching configuration at /etc/puppet/localconfig.yaml info: No classes to store notice: Starting configuration run notice: /File[/etc/local/sysctl]/ensure: created notice: /File[/etc/local/sysctl/etc]/ensure: created notice: /File[/etc/local/sysctl/etc/local]/ensure: created notice: /File[/etc/local/sysctl/etc/local/sysctl.conf]/ensure: created notice: /File[/etc/local/sysctl/etc/local/sysctl]/ensure: created notice: Finished configuration run in 2.31 seconds instead of getting a single notice: /File[/etc/local/sysctl]/ensure: created Best regards, Jozsef -- E-mail : kadlec@sunserv.kfki.hu, kadlec@blackhole.kfki.hu PGP key: http://www.kfki.hu/~kadlec/pgp_public_key.txt Address: KFKI Research Institute for Particle and Nuclear Physics H-1525 Budapest 114, POB. 49, Hungary
Hi, On Thu, 11 Jan 2007, Kadlecsik Jozsi wrote:> > > What I wanted is the following: > > > > > > +++++ fileserver.conf +++++ > > > [system] > > > path /services/puppet/common/ > > > allow * > > > > > > +++++ site.pp +++++++++++++ > > > file { "/etc/local/sysctl": > > > owner => root, > > > group => root, > > > mode => 750, > > > source => "puppet://puppet/system/$name" > > > } > > > > > > and get "/etc/local/systctl" from > > > "/services/puppet/common/etc/local/sysctl" on the server.For the record of the archive: it was a misconfiguration on my part. Because of the leading slash in $name, instead of source => "puppet://puppet/system/$name" the correct source parameter is source => "puppet://puppet/system$name" Best regards, Jozsef -- E-mail : kadlec@sunserv.kfki.hu, kadlec@blackhole.kfki.hu PGP key: http://www.kfki.hu/~kadlec/pgp_public_key.txt Address: KFKI Research Institute for Particle and Nuclear Physics H-1525 Budapest 114, POB. 49, Hungary