← Back to issue list

Cannot adjust systemd service definition

View original Launchpad issue

Metadata

Project
snapcraft
Number
#1619154
Type
issue
State
open
Author
~stub
Labels
Created
2016-09-01 07:49:11.740206+00:00
Updated
2017-04-26 13:53:47.935764+00:00
Closed
2017-04-26 13:53:47.117640+00:00

Current evaluation

No evaluation has been recorded for this issue yet.

Issue body

There seems to be no way to configure the generated systemd service files. Most importantly for me, you can't specify how the service is stopped. Cannot override the default TimeoutStopSec. This means that PostgreSQL services shutdown may be corrupted if shutdown under load, which is what can happen when it gets a SIGTERM at the wrong time. You can't specify what 'systemctl reload' does, so configuration changes won't take affect unless you bounce the service completely or write your own 'reload' script in the snap. Per the example at https://www.postgresql.org/docs/9.6/static/server-start.html, PostgreSQL should use Type=notify. This way, dependent services will not be started until PostgreSQL startup has completed and all sockets available. You can't specify the PID for forking services. And I'm sure there are many more that other snap will need.

Evaluation history

No evaluation history available.