ansible/ansible — pull request #2005 by ftao (2013-02-07 08:20:17+00:00)
Title: always restart the program when state=restarted

The supervisorctl module current behavior is
1. when state = restarted , it will not restart the program if it is not running
2. when state = started , it will not reload the config file

I run into a problem:
1. have a bad version of supervisor config in server . (bad argument, the program won't started)
2. upload an new version of config that works
3. `supervisorctl name=xxxx state=started` or
`supervisorctl name=xxxx state=restarted` will make it using the latest config and start the program .

I suggest the change the behavior of the `restarted` state, which should start the program if it is not running . Other similar modules works that way , for example `service` module .