mirror of
https://github.com/gitlabhq/gitlab-recipes.git
synced 2026-01-08 22:18:02 -05:00
- Do not use a target to specify dependencies. - Added postgresql and mysqld as optional dependencies. The service files work if the user has installed mysql or postgres either. - Removed ExecStop in gitlab-unicorn.service. It is entirely wrong to do it in such a way, see [1] - Added daemonize flags as it fixes systemd errors and warnings. Without this flags I was not able to start/stop a service properly because systemd has caught the wrong MainPIDs. Furthermore I had problems with service timouts as systemd caught the wrong return codes and considered the services as failed. - Updated README.md. [1]: http://lists.freedesktop.org/archives/systemd-devel/2014-January/016417.html
26 lines
797 B
Desktop File
26 lines
797 B
Desktop File
#####################################################
|
|
#
|
|
# GitLab version : 5.x - 7.x
|
|
# Contributors : davispuh, mtorromeo, axilleas, boeserwolf91, Stefan Tatschner (rumpelsepp)
|
|
# Downloaded from : https://gitlab.com/gitlab-org/gitlab-recipes/tree/master/init/systemd
|
|
#
|
|
####################################################
|
|
|
|
[Unit]
|
|
Description=GitLab Unicorn Server
|
|
Requires=redis.service
|
|
Wants=mysqld.service postgresql.service
|
|
After=redis.service mysqld.service postgresql.service
|
|
|
|
[Service]
|
|
User=git
|
|
WorkingDirectory=/home/git/gitlab
|
|
Environment=RAILS_ENV=production
|
|
SyslogIdentifier=gitlab-unicorn
|
|
PIDFile=/home/git/gitlab/tmp/pids/unicorn.pid
|
|
|
|
ExecStart=/usr/bin/bundle exec "unicorn_rails -D -c /home/git/gitlab/config/unicorn.rb -E production"
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|