Last active
April 29, 2024 13:15
-
-
Save jwc20/b057c9f10927862c159ec69683ce2d46 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
sudo systemctl daemon-reload | |
sudo systemctl stop 00waasu_scraper.service | |
sudo systemctl disable 00waasu_scraper.service | |
sudo systemctl enable --now waasu_scraper.timer | |
sudo systemctl status waasu_scraper.timer 00waasu_scraper.service |
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
# /etc/systemd/system/00waasu_scraper.service | |
[Unit] | |
Description=Work At A Startup Scraper | |
Wants=waasu_scraper.timer | |
[Service] | |
Type=oneshot | |
User=cjw | |
ExecStart=/usr/bin/python3.10 /home/cjw/Development/waasuapi/example.py | |
[Install] | |
WantedBy=multi-user.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
# /etc/systemd/system/waasu_scraper.timer | |
[Unit] | |
Description=Run waasu_scraper every day | |
Requires=waasu_scraper.service | |
[Timer] | |
OnCalendar=*-*-* 0/24:00:00 | |
Persistent=true | |
[Install] | |
WantedBy=timers.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment