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=Wormhole Transit Relay | |
[Service] | |
Type=forked | |
ExecStart=/opt/tr-venv/bin/twistd transitrelay | |
Restart=on-failure | |
[Install] | |
WantedBy=default.target |
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
#!/usr/bin/env bash | |
## run (only once) processes which spawn with the same name | |
function run { | |
if (command -v $1 && ! pgrep $1); then | |
$@& | |
fi | |
} | |
## run (only once) processes which spawn with different name |