YunoHost-Apps / borg_ynh

An experimental Borg implementation for YunoHost
https://www.borgbackup.org/
GNU Affero General Public License v3.0
19 stars 25 forks source link

Stop backing up on reboot #92

Open Thatoo opened 3 years ago

Thatoo commented 3 years ago

Describe the bug

Borg backup at each start, even reboot...

Steps to reproduce

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.

zamentur commented 3 years ago

It's a bug, not a feature ^^

zamentur commented 3 years ago

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
Thatoo commented 3 years ago

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
:~$
zamentur commented 3 years ago

I think you can avoid that behaviour by running:

yunohost service disable borg