Last active
February 2, 2017 15:30
-
-
Save merqlove/19b66736ed36628e71d1749856abdbef to your computer and use it in GitHub Desktop.
SystemD Puma example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=MRCR Sites Puma Server | |
[email protected] mongod.service | |
[email protected] mongod.service | |
[email protected] mongod.service | |
[Service] | |
Type=simple | |
User=merkulov | |
PIDFile=/srv/apps/sites_mrcr_ru/shared/tmp/pids/puma.pid | |
WorkingDirectory=/srv/apps/sites_mrcr_ru/current | |
EnvironmentFile=/srv/apps/sites_mrcr_ru/.rbenv-vars | |
Environment=RAILS_ENV=production | |
Environment=PUMA_CONFIG_FILE=/srv/apps/sites_mrcr_ru/shared/config/puma.rb | |
ExecStart=/opt/rbenv/shims/bundle exec puma -C ${PUMA_CONFIG_FILE} | |
ExecStop=/opt/rbenv/shims/bundle exec pumactl -F ${PUMA_CONFIG_FILE} stop | |
ExecReload=/opt/rbenv/shims/bundle exec pumactl -F ${PUMA_CONFIG_FILE} phased-restart | |
TimeoutSec=15 | |
Restart=always | |
StandardInput=null | |
StandardOutput=syslog | |
StandardError=syslog | |
SyslogIdentifier=%n | |
KillMode=process | |
TimeoutStopSec=5 | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment