mirror of
https://github.com/brunofontes/linuxShortcuts.git
synced 2025-04-20 09:57:12 +00:00
Compare commits
No commits in common. "2b36d7c555cd72fcf664a1c4f59d1ecebb9f3e11" and "b34416de141e729aaa968e42e84217001741b524" have entirely different histories.
2b36d7c555
...
b34416de14
@ -1 +0,0 @@
|
|||||||
CONTABO_BACKUP_PATH="/home/bruno/Backups/Contabo"
|
|
1
Services/backup-contabo.service
Normal file → Executable file
1
Services/backup-contabo.service
Normal file → Executable file
@ -3,4 +3,3 @@ Description=Backup contabo daily
|
|||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
ExecStart=/home/bruno/Backups/Contabo/backup-contabo.sh
|
ExecStart=/home/bruno/Backups/Contabo/backup-contabo.sh
|
||||||
EnvironmentFile=/home/bruno/Apps/linuxShortcuts/Services/backup-contabo.env
|
|
||||||
|
@ -1,10 +1,4 @@
|
|||||||
#! /bin/bash
|
#! /bin/bash
|
||||||
|
|
||||||
if [[ `nmcli -t -f GENERAL.METERED dev show | grep "METERED:yes"` ]]; then
|
|
||||||
echo Backup does not work on metered connections
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z $CONTABO_BACKUP_PATH ]]; then
|
if [[ -z $CONTABO_BACKUP_PATH ]]; then
|
||||||
echo CONTABO_BACKUP_PATH environment not set
|
echo CONTABO_BACKUP_PATH environment not set
|
||||||
exit 1
|
exit 1
|
||||||
|
@ -1,6 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=Backup joplin weekly
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
User=bruno
|
|
||||||
ExecStart=/home/bruno/Apps/linuxShortcuts/Services/backup-joplin.sh
|
|
@ -1,15 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
BACKUP_DIR="/home/bruno/Backups/Joplin"
|
|
||||||
JOPLIN_BIN="/bin/joplin"
|
|
||||||
|
|
||||||
$JOPLIN_BIN sync
|
|
||||||
$JOPLIN_BIN e2ee decrypt
|
|
||||||
|
|
||||||
# Delete old backups
|
|
||||||
cd "$BACKUP_DIR"
|
|
||||||
rm -r "./joplin.jex"
|
|
||||||
rm -rf "./MD"
|
|
||||||
|
|
||||||
$JOPLIN_BIN --log-level debug export --format jex "$BACKUP_DIR/joplin.jex"
|
|
||||||
$JOPLIN_BIN --log-level debug export --format md "$BACKUP_DIR/MD"
|
|
@ -1,11 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=Backup joplin weekly
|
|
||||||
|
|
||||||
[Timer]
|
|
||||||
Persistent=true
|
|
||||||
OnCalendar=Thu *-*-* 10:10:00
|
|
||||||
WakeSystem=true
|
|
||||||
#DayOfWeek Year-Month-Day Hour:Minute:Second
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=timers.target
|
|
Loading…
Reference in New Issue
Block a user