Skip to content

Instantly share code, notes, and snippets.

@vodolaz
Created September 17, 2021 18:10
Show Gist options
  • Save vodolaz/7029e75c57057fe0c259fe4b162d49f1 to your computer and use it in GitHub Desktop.
Save vodolaz/7029e75c57057fe0c259fe4b162d49f1 to your computer and use it in GitHub Desktop.
script for misha
#!/bin/bash
cat <<EOF | sudo tee /etc/systemd/system/superscript.service
[Unit]
Description=superscript
[Service]
ExecStart=/usr/bin/python3.8 _____full_path_to_script______
[Install]
WantedBy=multi-user.target
EOF
# reload systemd
systemctl daemon-reload
# enable service auto start
systemctl enable superscript.service
# start service
systemctl start superscript.service
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment