mirror of
https://github.com/msfjarvis/server-config
synced 2025-08-14 10:37:02 +05:30
Remove unused units
Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com>
This commit is contained in:
parent
0ea4788a1e
commit
99f807dd3d
3 changed files with 1 additions and 51 deletions
|
@ -1,22 +0,0 @@
|
|||
[Unit]
|
||||
Description=Telegram notifier service for androidx-release-watcher
|
||||
Wants=release-watcher-recent.timer
|
||||
|
||||
[Service]
|
||||
WorkingDirectory=/home/bot/androidx-release-watcher
|
||||
ExecStart=/home/bot/androidx-release-watcher/venv/bin/python telegram_notifier.py
|
||||
|
||||
; Use graceful shutdown with a reasonable timeout
|
||||
KillMode=mixed
|
||||
KillSignal=SIGQUIT
|
||||
TimeoutStopSec=5s
|
||||
|
||||
; Use private /tmp and /var/tmp, which are discarded after the process stops.
|
||||
PrivateTmp=true
|
||||
; Use a minimal /dev (May bring additional security if switched to 'true', but it may not work on Raspberry Pi's or other devices, so it has been disabled in this dist.)
|
||||
PrivateDevices=false
|
||||
; Make /usr, /boot, /etc and possibly some more folders read-only.
|
||||
ProtectSystem=full
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
|
@ -1,12 +0,0 @@
|
|||
[Unit]
|
||||
Description=Run shopify-recent every 24 hours with a 30 minute leeway
|
||||
Requires=androidx-release-watcher.service
|
||||
|
||||
[Timer]
|
||||
Unit=androidx-release-watcher.service
|
||||
OnUnitInactiveSec=24h
|
||||
RandomizedDelaySec=15m
|
||||
AccuracySec=1s
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
18
update.sh
18
update.sh
|
@ -8,8 +8,7 @@ function prettyPrint {
|
|||
}
|
||||
|
||||
# Grab all service names
|
||||
declare -a services=('androidx-release-watcher' 'caddy' 'gitea' 'horbiswalls-bot' 'mirror-bot' 'mirror-bot-2' 'uno-bot' 'walls-bot' 'walls-bot-2')
|
||||
declare -a timers=('release-watcher-recent')
|
||||
declare -a services=('caddy' 'gitea' 'horbiswalls-bot' 'mirror-bot' 'mirror-bot-2' 'uno-bot' 'walls-bot' 'walls-bot-2')
|
||||
|
||||
# Now loop through each service and install it
|
||||
for service in "${services[@]}"; do
|
||||
|
@ -26,18 +25,3 @@ for service in "${services[@]}"; do
|
|||
sudo systemctl enable "${service}"
|
||||
fi
|
||||
done
|
||||
|
||||
for timer in "${timers[@]}"; do
|
||||
if [ "${1}" ] && [[ "${timer}" != "${1}" && "${timer}.timer" != "${1}" ]]; then
|
||||
continue
|
||||
fi
|
||||
prettyPrint "Installing ${timer}"
|
||||
sudo cp -v "${timer}.timer" /etc/systemd/system/
|
||||
sudo systemctl daemon-reload
|
||||
prettyPrint "Restarting ${timer}"
|
||||
sudo systemctl restart "${timer}".timer
|
||||
if [ ! -f "/etc/systemd/system/multi-user.target.wants/${timer}.timer" ]; then
|
||||
prettyPrint "Enabling ${timer}"
|
||||
sudo systemctl enable "${timer}".timer
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue