You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Validate and update the guide based on a suggestion in Disqus:
Just a detail - you do NOT need to add myservice.service definition in /lib/systemd/... since those are intended to be for rmp/apt or other package manager installations.
The text was updated successfully, but these errors were encountered:
I came here from the comment on Disqus. I wanted to add a bit of information if this gets revisited, since it's still open:
I agree that adding custom service files to /lib/systemd is wrong and /etc/systemd is correct. I used to do that.
However, equally acceptable, and possibly preferable is to store unit files with your application. Calling systemctl enable /path/to/my.service will still create the correct symlink if an Install section is present in the unit file. Or if not, systemctl link /path/to/my.service will symlink into /etc/systemd/system. This can save a step in deployment if you update your unit file. I also think it's appropriate for the unit file to live in the application, but I believe this is personal preference and not necessarily best practice.
To add further, Units that belong to a package or the system should be modified not by editing the file in /lib/systemd, but rather by using systemctl edit foo where foo is the name of the service.
Validate and update the guide based on a suggestion in Disqus:
Just a detail - you do NOT need to add myservice.service definition in /lib/systemd/... since those are intended to be for rmp/apt or other package manager installations.
The text was updated successfully, but these errors were encountered: