ansible/lib
Kira Rose 46cd8ba7cd Check Windows service status before nssm STOP (#28379)
* Check Windows service status before nssm STOP

Add a condition on calling nssm STOP inside Nssm-Remove, to check whether or not a service has already been stopped. Currently nssm throws an exception:

```
failed: [...] (item=...) => {"changed": false, "failed": true, "item": "...", "msg": "an exception occurred when invoking NSSM: serviceName: STOP: The service has not been started."}
failed: [...] (item=...) => {"changed": false, "failed": true, "item": "...", "msg": "an exception occurred when invoking NSSM: serviceName: The service has not been started."}
```

Behaviour after change:

```
ok: [...] => (item=...)
ok: [...] => (item=...)
```

* Added named parameter to new Get-Service cmdlet
2017-08-24 08:40:48 -04:00
..
ansible Check Windows service status before nssm STOP (#28379) 2017-08-24 08:40:48 -04:00