YunoHost-Apps/borg_ynh

Stop backing up on reboot

Thatoo opened this issue · 4 comments

Describe the bug

Borg backup at each start, even reboot...

Steps to reproduce

  • reboot yunohost
  • borg backup on startup
  • takes all resources (cpu, bandwith...)

Expected behavior

Borg backup every week (in the middle of a night, no disturbance). It is enough for me. I don't need it to backup also everytime I reboot my server. I'd like to be able to stop the option to backup on startup.

It's a bug, not a feature ^^

Hi @Thatoo
Could it be possible to get the result of those commands ?

cat /etc/systemd/system/borg.service
cat /etc/systemd/system/borg.timer

Sure, here they are, hoping it helps :

:~$ cat /etc/systemd/system/borg.service
[Unit]
Description=Run backup borg
After=network.target

[Service]
Type=oneshot
ExecStart=/usr/bin/sudo /usr/local/bin/backup-with-borg borg
User=borg
Group=borg

#[Install]
#WantedBy=multi-user.target
:~$ cat /etc/systemd/system/borg.timer
[Unit]
Description=Run backup borg regularly

[Timer]
OnCalendar=Weekly

[Install]
WantedBy=timers.target
:~$

I think you can avoid that behaviour by running:

yunohost service disable borg