mirror of
https://github.com/openoms/joininbox.git
synced 2026-08-17 13:07:15 +02:00
24 lines
No EOL
423 B
Bash
24 lines
No EOL
423 B
Bash
#!/bin/bash
|
|
|
|
SCRIPT="$1"
|
|
WALLET="$2"
|
|
|
|
echo "
|
|
[Unit]
|
|
Description=$SCRIPT
|
|
|
|
[Service]
|
|
ExecStart=python /home/joinin/joininbox/scripts/scriptstarter.py $SCRIPT.py $WALLET.jmdat
|
|
User=joinin
|
|
Group=joinin
|
|
Type=simple
|
|
KillMode=process
|
|
TimeoutSec=60
|
|
Restart=always
|
|
RestartSec=60
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|
|
" | sudo tee /etc/systemd/system/$SCRIPT.service
|
|
sudo systemctl enable $SCRIPT
|
|
sudo systemctl start $SCRIPT |