[Unit] Description=__APP__-web After=network.target [Service] Type=simple User=__APP__ WorkingDirectory=__FINALPATH__ Environment="RAILS_ENV=production" Environment="PORT=__PORT_WEB__" Environment=UNICORN_LISTENER=__FINALPATH__/tmp/sockets/unicorn.sock ExecStart=__RBENV_ROOT__/versions/__APP__/bin/bundle exec unicorn --config config/unicorn.rb -E production ExecReload=/bin/kill -SIGUSR1 $MAINPID TimeoutSec=60 RestartSec=60 Restart=on-failure StandardError=syslog [Install] WantedBy=multi-user.target