voxpupuli / puppet-nfs

Installs and configures NFS server and clients
https://forge.puppet.com/modules/derdanne/nfs
Apache License 2.0
16 stars 81 forks source link

feat: add a parameter to define if we manage nfs server service ensure state #183

Open ttousai opened 5 months ago

ttousai commented 5 months ago

We want puppet-nfs to manage the NFS service but not manage the service state (running/stopped) because that state is managed by another tool.

TheMeier commented 5 months ago

That sounds like an anti pattern to me. No 2 tools should manage the same resource

tuxmea commented 4 months ago

Usually I would agree with the comment https://github.com/voxpupuli/puppet-nfs/pull/183#issuecomment-2143917508

But other modules are doing the same: class parameter to set the ensure or enable state.

@ttousai can you please rebase your branch?

h-haaks commented 4 months ago

I tend to agree with @TheMeier on this one. We usually have params to manage the service or not, and if we do manage it we have params to ensure stopped/running and enabled/disabled ( at boot )

If there is another tool involved managing the service state that tool should manage the enabled/disabled state as well.

tuxmea commented 4 months ago

There are reasons why puppet should not start the service. e.g. nfs ist started by pacemaker/corosync. From my point of view the request to have a parameter makes sense. Maybe the description was a little bit misleading.

h-haaks commented 4 months ago

To me the example you mention is exactly the kind of edge case where I would set manage_server_service to false and manage the service in a profile class.