Pastie now auto-senses if line-wrap is a bad or good idea. Feedback?
## mark a section (Learn more)
class sshdconfig { #hopefulyl this will work when we have a working user class #sshd_config{ puppet: authorizedusers => $engineringuserclass::engineringuserlist } sshd_config{ puppet: listenaddress => $ipaddress } } define sshd_config($listenaddress) { #sshd_config refered to as alias from now on file { sshd_config: path => $operatingsystem ? { solaris => "/usr/local/etc/ssh/sshd_config", debian => "/etc/ssh/sshd_config", default => "/etc/ssh/sshd_config" }, owner => root, group => root, mode => 444, content => template("sshdconfig/sshd_config.erb"), notify => Service[ssh], alias => sshd_config, } # service { ssh: # name => $operatingsystem ? { # fedora => "sshd", # debian => "ssh", # ubuntu => "ssh", # default => "ssh", # }, # running => true, # subscribe => file[sshd_config] # } service { ssh: running => true, subscribe => File[sshd_config] } } on the client i get err: Could not retrieve catalog: Invalid parameter 'running' for type 'Service' at /etc/puppet/modules/sshdconfig/manifests/init.pp:40 on node puppetslave.sohonet.dcn.sohonet.dcn ok ive updated the service to service { ssh: ensure => "running", subscribe => File[sshd_config] } } and now i get err: /File[/var/lib/puppet/lib]: Failed to retrieve current state of resource: can't convert nil into String Could not describe /plugins: can't convert nil into String info: /File[sshd_config]: Adding aliases "sshd_config" info: Caching catalog at /var/lib/puppet/state/localconfig.yaml notice: Starting catalog run notice: Finished catalog run in 0.68 seconds ^Cnotice: Caught INT; shutting down notice: Shutting down but ssh doesnt apear to be running cat /var/run/sshd.pid cat: /var/run/sshd.pid: No such file or directory
This paste will be private.
From the Design Piracy series on my blog: