Created
July 3, 2018 07:47
-
-
Save sanzstez/5bd330f85e2ad982e8d2155fe8dd4f61 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| cat ~/.config/default/action_cable | |
| RVM_STRING = 2.4.3@schoolhire-app | |
| PUMA_OPTS = "-e staging -p 28080 cable/config.ru" | |
| DAEMON = puma | |
| EXEC_COMMAND = cd /application/current && /.rvm/bin/rvm-shell ${RVM_STRING} -c "bundle exec ${DAEMON} ${PUMA_OPTS}" | |
| ~/.config/systemd/user/action_cable.service | |
| [Unit] | |
| Description = Action Cable | |
| [Service] | |
| ExecStart = /bin/bash -c ${EXEC_COMMAND} | |
| ExecReload=/bin/kill -s USR2 $MAINPID | |
| KillSignal = SIGQUIT | |
| TimeoutStopSec = 62 | |
| KillMode = process | |
| Restart = on-failure | |
| RestartSec = 60 | |
| EnvironmentFile = /home/schoolhire/.config/default/action_cable | |
| PIDFile=/home/schoolhire/application/shared/tmp/pids/action_cable.pid | |
| [Install] | |
| WantedBy = default.target |
This file contains hidden or 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
| systemd enable action_cable |
This file contains hidden or 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
| https://wiki.archlinux.org/index.php/Systemd/User | |
| loginctl enable-linger username | |
| щоб при завершені сесії юзера не завершувалися процеси systemd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment