summarylogtreecommitdiffstats
path: root/gitlab-unicorn.service
diff options
context:
space:
mode:
authorLopo2015-06-17 20:07:23 +0200
committerLopo2015-06-17 20:07:23 +0200
commit8da6485dad5022d64a64ded05e93e52dbf6a3070 (patch)
tree5e271982edf9b66135300a9c1d55a31ce1005fa2 /gitlab-unicorn.service
downloadaur-8da6485dad5022d64a64ded05e93e52dbf6a3070.tar.gz
Initial import
Diffstat (limited to 'gitlab-unicorn.service')
-rw-r--r--gitlab-unicorn.service30
1 files changed, 30 insertions, 0 deletions
diff --git a/gitlab-unicorn.service b/gitlab-unicorn.service
new file mode 100644
index 000000000000..b1e9370244a9
--- /dev/null
+++ b/gitlab-unicorn.service
@@ -0,0 +1,30 @@
+[Unit]
+Description=GitLab Unicorn Server
+Requires=redis.service
+Wants=mysqld.service postgresql.service
+After=redis.service mysqld.service postgresql.service network.target
+
+[Service]
+User=gitlab
+Group=gitlab
+WorkingDirectory=<DATADIR>
+Environment=RAILS_ENV=production
+SyslogIdentifier=gitlab-unicorn
+PIDFile=/run/gitlab/unicorn.pid
+
+RuntimeDirectory=gitlab
+RuntimeDirectoryMode=775
+
+CapabilityBoundingSet=
+PrivateTmp=true
+PrivateDevices=true
+ProtectSystem=full
+ProtectHome=true
+NoNewPrivileges=true
+
+ExecStart=/usr/bin/bundle exec "unicorn_rails -c <DATADIR>/config/unicorn.rb -E production"
+ExecStop=/usr/bin/kill -QUIT $MAINPID
+ExecReload=/usr/bin/kill -USR2 $MAINPID
+
+[Install]
+WantedBy=multi-user.target