initial commit
authorNils <forssennils@gmail.com>
Sat, 9 Nov 2024 03:23:25 +0000 (04:23 +0100)
committerNils <forssennils@gmail.com>
Sat, 9 Nov 2024 03:23:25 +0000 (04:23 +0100)
backup_script.bat [new file with mode: 0644]

diff --git a/backup_script.bat b/backup_script.bat
new file mode 100644 (file)
index 0000000..19030aa
--- /dev/null
@@ -0,0 +1,11 @@
+cd C://users//forss
+
+tar -cvpzf backup/backup.tar.gz ./Documents ./Videos ./Pictures ./Music ./Downloads D:/Documents D:/Pictures D:/Videos
+
+scp backup/backup.tar.gz nils@%SERVER_IP%:~/backup_tar/
+
+ssh nils@%SERVER_IP% cp backup_tar/backup.tar.gz /backup/
+
+ssh nils@%SERVER_IP% tar -xpvf /mnt/USB/backup/backup.tar.gz -C /backup/
+
+ssh nils@%SERVER_IP% rm -rf backup_tar/backup.tar.gz
\ No newline at end of file