FS#60970 - [nginx] sytemd service does not restart on error

Attached to Project: Arch Linux
Opened by Mike Schliep (schliep) - Wednesday, 05 December 2018, 05:18 GMT
Last edited by Massimiliano Torromeo (mtorromeo) - Saturday, 16 September 2023, 09:21 GMT
Task Type Feature Request
Category Packages: Extra
Status Closed
Assigned To Massimiliano Torromeo (mtorromeo)
Levente Polyak (anthraxx)
Giancarlo Razzolini (grazzolini)
T.J. Townsend (blakkheim)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:
nginx does not restart if started with systemd it exits with an error code or the starting times out.

The solution is to add a Restart= option to the service file.

Systemd reccomends(https://www.freedesktop.org/software/systemd/man/systemd.service.html):
[Service]
Restart=on-failure

openssh uses:

[Service]
Restart=always

Both are good options, I like "always" as it restarts if nginx exits for any reason.
This task depends upon

Closed by  Massimiliano Torromeo (mtorromeo)
Saturday, 16 September 2023, 09:21 GMT
Reason for closing:  Implemented
Additional comments about closing:  nginx-1.24.0-2
Comment by Buggy McBugFace (bugbot) - Tuesday, 08 August 2023, 19:11 GMT
This is an automated comment as this bug is open for more then 2 years. Please reply if you still experience this bug otherwise this issue will be closed after 1 month.

Loading...