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

/etc/sysconfig is RHEL/CentOS specific #3

Open
onitake opened this issue Sep 19, 2018 · 2 comments
Open

/etc/sysconfig is RHEL/CentOS specific #3

onitake opened this issue Sep 19, 2018 · 2 comments

Comments

@onitake
Copy link

onitake commented Sep 19, 2018

The path for the systemd unit environment file is currently hard-coded to /etc/sysconfig/activemq .

This will work on most installations, but /etc/sysconfig/ is a path specific to RHEL/CentOS/etc.
On Debian, for example, init script environment files are stored in /etc/default/ .
Even on RH, /etc/default/ has started to see some use lately.

I recommend making the path customisable via an Ansible variable or moving environment variables directly into the service file.

Quote the systemd overlord himself:

Use of EnvironmentFile= is pretty much always a bad idea, and we probably should never have added that, since it invites packagers to reintroduce the /etc/default/ and /etc/sysconfig/ madness we try to remove.
-- systemd/systemd#618 (comment)

@onitake
Copy link
Author

onitake commented Sep 19, 2018

Also, it may be a good idea to make the installation mode independent of the package manager...

@hagzag
Copy link
Contributor

hagzag commented Sep 21, 2018

PR's are welcome

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

No branches or pull requests

2 participants