Working script modified for use with working systemd service
This commit is contained in:
10
install.sh
10
install.sh
@@ -59,8 +59,14 @@ setup_backup () {
|
||||
|
||||
sudo cp -r borg /opt/
|
||||
sudo chown -R "root:root" /opt/borg
|
||||
sudo chmod -R 755 /opt/borg
|
||||
find /opt/borg -type d -exec sudo chmod 755 {} \;
|
||||
find /opt/borg -type f -exec sudo chmod 644 {} \;
|
||||
sudo chmod -R 755 /opt/borg/bin
|
||||
sudo chmod 700 /opt/borg/etc
|
||||
sudo chmod 700 /opt/borg/ssh
|
||||
sudo ln -s /opt/borg/systemd/backup.service /etc/systemd/system/backup.service
|
||||
sudo ln -s /opt/borg/systemd/backup.timer /etc/systemd/system/backup.timer
|
||||
sudo systemctl daemon-reload
|
||||
|
||||
local escaped_path=$(escape_sed "$repopath")
|
||||
local escaped_pass=$(escape_sed "$raw_passphrase")
|
||||
@@ -74,7 +80,7 @@ EOF
|
||||
printf "Installation complete.\n"
|
||||
|
||||
generate_recovery_file "$repopath" "$raw_passphrase"
|
||||
|
||||
sudo systemctl enable --now backup.timer
|
||||
}
|
||||
|
||||
setup_encrypted_backup () {
|
||||
|
||||
Reference in New Issue
Block a user