Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ansible 2.2 service module requires systemd unit file for Ubuntu 16.04 #20

Closed
geerlingguy opened this issue Nov 2, 2016 · 3 comments · Fixed by #23
Closed

Ansible 2.2 service module requires systemd unit file for Ubuntu 16.04 #20

geerlingguy opened this issue Nov 2, 2016 · 3 comments · Fixed by #23

Comments

@geerlingguy
Copy link
Contributor

Ansible 2.2 introduced some changes to the way the service module works with older init scripts, so the following happens under Ubuntu 16.04 if using Ansible 2.2+:

TASK [arknoll.selenium : Ensure selenium is running] ***************************
fatal: [drupalvm]: FAILED! => {"changed": false, "failed": true, "msg": "Could not find the requested service \"'selenium'\": "}

For my roles that were encountering similar issues, I had to add a systemd unit file and this solved the issue because the service module can use that instead of the custom init script.

See:

@MassiveHiggsField
Copy link

I've added a pr that switches to unit files for debian >= 8

@kporras07
Copy link
Contributor

Hi there; any update on this?
Would you accept a PR with this change?

@geerlingguy
Copy link
Contributor Author

This PR did a lot of the work (but was a bit Debian-centric—any systemd-based distro should use the unit file): #22

A new PR would be helpful—I should think we could get it to work with CentOS 7, Debian 8, Ubuntu 16.04, etc. (any systemd-default OS).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants