Bug 873382

Summary: Use SuccessExitStatus option in systemd service file
Product: [Fedora] Fedora Reporter: Andrei Lapshin <alapshin>
Component: uwsgiAssignee: Jorge Gallegos <kad>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 18CC: kad
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-01-23 01:25:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Andrei Lapshin 2012-11-05 17:22:31 UTC
Right now uWSGI have the following option in systemd service file: ExecStart=/usr/sbin/uwsgi --ini /etc/uwsgi.ini; [ $? -eq 30 ]

This command doesn't work for me because uwsgi can't find file /etc/uwsgi.ini; (with semicolon). Since version 189 [1] systemd have option SuccessExitStatus "which allow configuration of exit status (exit code or signal) which will be excepted from the restart logic, resp. consider successful".

Using this option service file can be rewritten as
ExecStart=/usr/sbin/uwsgi --ini /etc/uwsgi.ini
SuccessExitStatus=30


[1] http://cgit.freedesktop.org/systemd/systemd/tree/NEWS

Comment 1 Jorge Gallegos 2012-11-05 20:15:16 UTC
Sweet! I had this issue when I was adding systemd support as you can see here http://lists.unbit.it/pipermail/uwsgi/2012-July/004547.html. Will fix as this was really bugging me :)

Comment 2 Fedora Update System 2012-12-27 02:47:01 UTC
uwsgi-1.2.6-6.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/uwsgi-1.2.6-6.fc18

Comment 3 Fedora Update System 2012-12-27 20:53:02 UTC
Package uwsgi-1.2.6-6.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing uwsgi-1.2.6-6.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-21012/uwsgi-1.2.6-6.fc18
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2013-01-23 01:25:34 UTC
uwsgi-1.2.6-6.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.