So the issue that I have is that some of the files that we need to keep in hand are configuration files that are only read when the service starts. For instance, php on IIS. The php.ini file is read once when the service starts. So here is the scenario, a change is made to the php.ini and this is not correct, when DSC runs its next pass it changes the file back to what it should be however this is not reflected in IIS as the running config has not changed. The service needs to be restarted.
I have tried this in a script provider
copy the files
however this does not work, I have also substituted stop-service and start-service however these do not work either.
The question is, Does DSC provide a method to stop a service if the file is locked, or restart a service to reflect the change of a configuration file?