Hi All,
I am managing the config files of a service through puppet. This config file is being created through 2 separate modules and concatenated together. I am trying to modify the manifest in the module that installs the service so that whenever this config file changes (when the portion that comes from the 2nd module is concatenated to it), the service should restart. I tried using the notify/subscribe parameter here, but the service does not restart even though the content of the file gets changed.
However, if I use the notify parameter on the second module by associating it with the service created by the first module, the service gets restarted. I DO NOT want to do this way because it creates a dependency between these two modules which otherwise have been exclusive of one another. Is there some way around this? The change in the config file content is happening only at the portion that is being modified by the second module. But still, since I have used a subscribe parameter on the config, I believe that irrespective of which part of the file gets modified, the service must restart.
Does anybody have any idea if my understanding is correct or a way to work around this? Any help would be highly appreciated!!!
service {"DE_${service_name}":
enable => true,
ensure => true,
hasrestart => true,
hasstatus => true,
subscribe => File["${service_base_config_dir}/serverConfig.properties"]
}