On Fri, Jul 22, 2011 at 15:22, Cameron Thomas <[email protected]> wrote:
> This provider allows us to query the system state through "puppet
> resource", and manage the ensure, and enabled properties of services on
> Windows.
>
> This also adds support for a new enabled value of 'manual' on Windows
> only. With this we support the three major start types for services on
> Windows, with the following mapping of enabled to start type:
>
> true => Automatic
> false => Disabled
> manual => Manual (Demand)
>
> We use the win32-service gem to provide access to the Windows APIs for
> our operations. This does add a new gem requirement for running Puppet
> on Windows, but we were already requiring some gems from the same suite
> that win32-service is a part of.
>
> When referring to a service, the simple service name must be used,
> instead of the display name. For example, "snmptrap", instead of
> "SNMP Trap".
>
> All system services are reported in 'puppet resource service',
> including those started prior to run level 3 (system, device drivers,
> etc.). These services should probably not be managed, without careful
> thought and planning.
>
> This currently does not support being able to move a service from
> {enabled => false, ensure => stopped} to {enabled => true, ensure =>
> running} (or enabled => manual) in a single Puppet run, since Puppet
> currently always tries to sync ensure before any other property.
> Because of this, the puppet run will fail every time, and the service
> must first be managed as {ensure => stopped, enabled => true} (or
> enabled => manual), before it can be managed as running and automatic
> start or manual start.
Don't we have a `finalize` hook for providers, allowing us to batch
these operations? I think that might be usable here to deliver the
sync order required to deliver that as a working feature.
Daniel
--
⎋ Puppet Labs Developer – http://puppetlabs.com
♲ Made with 100 percent post-consumer electrons
--
You received this message because you are subscribed to the Google Groups
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-dev?hl=en.