theSoberSobber / Notifier

won't elaborate.
0 stars 0 forks source link

Service Code and General VPS Code #2

Open theSoberSobber opened 1 month ago

theSoberSobber commented 1 month ago
$ cat system/codeforces-monitor.timer
[Unit]
Description=Run Codeforces Monitor every 15 minutes

[Timer]
OnBootSec=5min
OnUnitActiveSec=15min
Unit=codeforces-monitor.service

[Install]
WantedBy=timers.target

$ cat system/codeforces-monitor.service
[Unit]
Description=Codeforces Profile Monitor
After=network.target

[Service]
Type=simple
User=meso
WorkingDirectory=/home/meso/Notifier/Notify
ExecStart=/home/meso/.pyenv/shims/python /home/meso/Notifier/Notify/main.py
Restart=on-failure

[Install]
WantedBy=multi-user.target
theSoberSobber commented 1 month ago
# status
systemctl status codeforces-monitor.timer

# logs
sudo journalctl -u codeforces-monitor.service -n 50
theSoberSobber commented 1 month ago
screen.sh
sudo vbetool dpms off
theSoberSobber commented 1 month ago
$ cat startVnc.sh
x11vnc -usepw -display :0
theSoberSobber commented 1 month ago
$ cat startNtfy.sh
sudo /home/meso/duckdns/duck.sh
sudo ntfy serve --listen-http :8083  --listen-https :8080 --cert-file /etc/letsencrypt/live/ntfyserver.duckdns.org/fullchain.pem --key-file /etc/letsencrypt/live/ntfyserver.duckdns.org/privkey.pem