jhoblitt / puppet-smartd

Manages the smartmontools package including the smartd daemon
Other
14 stars 24 forks source link

remove shell_config type/module dep #16

Closed jhoblitt closed 8 years ago

solarkennedy commented 10 years ago

How about this instead?

augeas { "enable_smartd":
  context => "/files/etc/default/smartmontools",
  changes => "set start_smartd yes",
}

(augeas is my new favorite puppet type apparently?)

jhoblitt commented 10 years ago

I'm not a Debian/Ubuntu user but I don't think messing with /etc/default/* is nessicary. The service type should deal with enabling LSB init scripts: https://github.com/puppetlabs/puppet/blob/master/lib/puppet/provider/service/debian.rb

solarkennedy commented 10 years ago

Na, its not an init script. /etc/default is analogous to /etc/sysconfig.

jhoblitt commented 10 years ago

Yes, I know. And it shouldn't be necessary to mess with it to get the service to start on boot.

jhoblitt commented 10 years ago

ugh, the smartmontools init script checks for it though... that is ridiculous.

lamawithonel commented 8 years ago

Any decision on this? All shell_config does is this:

augeas { "shell_config_start_smartd":
  lens    => 'Shellvars.lns',
  incl    => /etc/default/smartmontools,
  changes => 'set start_smartd "yes"',
}

Or in the case of $file_ensure == absent,

augeas { "shell_config_start_smartd":
  lens    => 'Shellvars.lns',
  incl    => /etc/default/smartmontools,
  changes => 'remove start_smartd',
}

I can write up an alternate PR, if you need.

jhoblitt commented 8 years ago

@lamawithonel That would be fantastic!

jhoblitt commented 8 years ago

superseded by #47