scripts
This commit is contained in:
parent
a3526fc415
commit
80274dee8a
2 changed files with 305 additions and 4 deletions
|
@ -23,12 +23,12 @@ echo "EXCLUDING ./Downloads & ./VirtualBoxVMs" | tee -a $backupDate-rob-homedir-
|
||||||
tar -czvf --exclude='./Downloads' --exclude='./VirtualBoxVMs' $backupDate-rob-homedir-backup.tar.gz /home/rob
|
tar -czvf --exclude='./Downloads' --exclude='./VirtualBoxVMs' $backupDate-rob-homedir-backup.tar.gz /home/rob
|
||||||
|
|
||||||
|
|
||||||
echo "Uploading backup file to BackBlaze..." | & tee -a $backupDate-rob-homedir-backup.log
|
#echo "Uploading backup file to BackBlaze..." | & tee -a $backupDate-rob-homedir-backup.log
|
||||||
rclone copy $backupDate-rob-homedir-backup.tar.gz b2:workhorse-laptop --progress >> $backupDate-rob-homedir-backup.log 2>&1
|
#rclone copy $backupDate-rob-homedir-backup.tar.gz b2:workhorse-laptop --progress >> $backupDate-rob-homedir-backup.log 2>&1
|
||||||
|
|
||||||
# remove the tar file from the main home folder after it's copied
|
# remove the tar file from the main home folder after it's copied
|
||||||
echo "Removing local backup cache..." | tee -a rob-homedir-backup-$backupDate.log
|
#echo "Removing local backup cache..." | tee -a rob-homedir-backup-$backupDate.log
|
||||||
rm -rf $backupDate-rob-homedir-backup.tar.gz >> rob-homedir-backup-$backupDate.log 2>&1
|
#rm -rf $backupDate-rob-homedir-backup.tar.gz >> rob-homedir-backup-$backupDate.log 2>&1
|
||||||
|
|
||||||
# Run System Update
|
# Run System Update
|
||||||
echo "Running System Update..." | tee -a rob-homedir-backup-$backupDate.log
|
echo "Running System Update..." | tee -a rob-homedir-backup-$backupDate.log
|
||||||
|
|
301
h -u origin main
Normal file
301
h -u origin main
Normal file
|
@ -0,0 +1,301 @@
|
||||||
|
[33mcommit a3526fc415abd73c587801e31effc0d578151e1b[m[33m ([m[1;36mHEAD -> [m[1;32mmain[m[33m)[m
|
||||||
|
Author: Rob McEwan <rob@localhost.localdomain>
|
||||||
|
Date: Fri Mar 14 11:49:09 2025 +1000
|
||||||
|
|
||||||
|
scripts
|
||||||
|
|
||||||
|
[33mcommit 9a0c54adb36acff4d1818a0f9c4e0c14bc93d18d[m[33m ([m[1;31morigin/main[m[33m, [m[1;31morigin/HEAD[m[33m)[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Mar 14 11:33:27 2025 +1000
|
||||||
|
|
||||||
|
Add homedir-backup.sh
|
||||||
|
|
||||||
|
[33mcommit 1183b118427a7e9d162f6080f9ab376c52f7d6e7[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Mar 13 17:21:31 2025 +1000
|
||||||
|
|
||||||
|
Update workhorse-laptop-backup.sh
|
||||||
|
|
||||||
|
[33mcommit 8803ff8376c415bcd3596a3c356d4aac94c0bb50[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Mar 13 17:20:49 2025 +1000
|
||||||
|
|
||||||
|
Update workhorse-laptop-backup.sh
|
||||||
|
|
||||||
|
[33mcommit 6bf573a312907a5058533da25aa0d9513f971e3a[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Mar 13 17:18:07 2025 +1000
|
||||||
|
|
||||||
|
Add workhorse-laptop-backup.sh
|
||||||
|
|
||||||
|
[33mcommit 3e1f089845992bea40556e0ef650fe13ec317ef7[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Wed Nov 20 23:37:48 2024 +1000
|
||||||
|
|
||||||
|
Update powershell/bts-onboarding.ps1
|
||||||
|
|
||||||
|
updated directories and trmm installer
|
||||||
|
|
||||||
|
[33mcommit a9648a11abda403e031c64a97edcdf25de1cf757[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Wed Nov 20 23:12:59 2024 +1000
|
||||||
|
|
||||||
|
Update powershell/bts-onboarding.ps1
|
||||||
|
|
||||||
|
commented out create support directories
|
||||||
|
|
||||||
|
[33mcommit d0b2b330f8ff9d8fadb0de401c523b4d84d8c377[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Wed Nov 20 23:10:37 2024 +1000
|
||||||
|
|
||||||
|
Update bts-anydesk.ps1
|
||||||
|
|
||||||
|
commented out add support directories
|
||||||
|
|
||||||
|
[33mcommit ee59daf704c866ad437f60521255d60bbd8ad7a2[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Nov 12 01:43:07 2024 +0000
|
||||||
|
|
||||||
|
Update bash/backuptrmm.sh
|
||||||
|
|
||||||
|
[33mcommit 36218092377519cb74da76b1874b9a96db0b38a0[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Nov 12 01:42:37 2024 +0000
|
||||||
|
|
||||||
|
Add bash/backuptrmm.sh
|
||||||
|
|
||||||
|
[33mcommit a726b0095a499371fb5a87755751d9f7600a5abb[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Nov 4 01:21:13 2024 +0000
|
||||||
|
|
||||||
|
Add powershell/bts-onboarding.ps1
|
||||||
|
|
||||||
|
[33mcommit 37e2fb2c4bb5e9d80daac0564346fdb80b662f39[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Nov 1 12:50:54 2024 +0000
|
||||||
|
|
||||||
|
Update bash/backupdocker2.sh
|
||||||
|
|
||||||
|
[33mcommit 9282267112225bacd1170c736cb22d959ef524a8[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Nov 1 06:47:39 2024 +0000
|
||||||
|
|
||||||
|
Update transmission-docker-compose.yml
|
||||||
|
|
||||||
|
[33mcommit fc97f7b1eba1e8045c9bfaf3f7b63524c9265ce0[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Nov 1 06:33:50 2024 +0000
|
||||||
|
|
||||||
|
Add transmission-docker-compose.yml
|
||||||
|
|
||||||
|
[33mcommit c160db9fe35ca11ab9535b01c7b4d3d99988d536[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Nov 1 06:33:26 2024 +0000
|
||||||
|
|
||||||
|
Add mount-nfs-boot
|
||||||
|
|
||||||
|
[33mcommit 40b00d9f4e01e92c62702b17c00b0fc25dea047f[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Oct 31 03:51:23 2024 +0000
|
||||||
|
|
||||||
|
Update RMD Psono Install.txt
|
||||||
|
|
||||||
|
[33mcommit 6f828fae0b8faa0e1bf6b60c614ca13188128d52[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Oct 31 03:29:08 2024 +0000
|
||||||
|
|
||||||
|
Update RMD Psono Install.txt
|
||||||
|
|
||||||
|
[33mcommit 1207d05c08150272c80726fd34b802a48f506e1b[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Oct 31 02:10:03 2024 +0000
|
||||||
|
|
||||||
|
Update RMD Psono Install.txt
|
||||||
|
|
||||||
|
[33mcommit a93cc2f758d7fe26e9daaa12b04cc89abd43756a[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Oct 31 02:06:58 2024 +0000
|
||||||
|
|
||||||
|
Update RMD Psono Install.txt
|
||||||
|
|
||||||
|
[33mcommit 26f36d93b6d9d6a713dbf7b607b4a5679b8e2cc2[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Thu Oct 31 02:03:59 2024 +0000
|
||||||
|
|
||||||
|
Add RMD Psono Install.txt
|
||||||
|
|
||||||
|
[33mcommit e2b577c05e8499edb7ce0d0675a999769b992031[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 11:39:53 2024 +0000
|
||||||
|
|
||||||
|
Update wireguard.sh
|
||||||
|
|
||||||
|
[33mcommit c5da616bc56f5caf030dc7ddf84d68359bdf60ad[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 11:37:55 2024 +0000
|
||||||
|
|
||||||
|
Add wireguard.sh
|
||||||
|
|
||||||
|
[33mcommit 5713971bc682cf242a9c528a3f7777e018fb42c3[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 11:08:56 2024 +0000
|
||||||
|
|
||||||
|
Add radius-docker-compose.yml
|
||||||
|
|
||||||
|
[33mcommit 9c765b4a7d650c799ed40dcbee23165d18c3df62[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 10:03:48 2024 +0000
|
||||||
|
|
||||||
|
Update bash/backupdocker1.sh
|
||||||
|
|
||||||
|
[33mcommit c58189d73686f452fdb902fbbf3a125d3012b7eb[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 09:53:18 2024 +0000
|
||||||
|
|
||||||
|
Add open-webui-docker-compose.yml
|
||||||
|
|
||||||
|
[33mcommit 331c0ebd0e286be56840d45d6e0be11f9f852678[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Tue Oct 29 05:23:41 2024 +0000
|
||||||
|
|
||||||
|
Add rmdblog-ghost-docker-run.sh
|
||||||
|
|
||||||
|
[33mcommit dd707225d022e34f7fcc63fde352f1934d224065[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 23:10:10 2024 +1000
|
||||||
|
|
||||||
|
c
|
||||||
|
|
||||||
|
[33mcommit 33d134735a96deec51369888260b7c8782e90bb9[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 23:04:37 2024 +1000
|
||||||
|
|
||||||
|
changes
|
||||||
|
|
||||||
|
[33mcommit 4ce891691f558dc2e2a480767f8d07d0b3dd7c84[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 22:02:33 2024 +1000
|
||||||
|
|
||||||
|
new
|
||||||
|
|
||||||
|
[33mcommit e0937b21264428678e5c50116f900b80f0c1a447[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 20:39:22 2024 +1000
|
||||||
|
|
||||||
|
1
|
||||||
|
|
||||||
|
[33mcommit ecf0b5a5a0947e638b9e256fe34f67061cf0f173[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 20:38:22 2024 +1000
|
||||||
|
|
||||||
|
renamed repo & changed folder structure
|
||||||
|
|
||||||
|
[33mcommit 49a84a90a98f10e0b99f82b537f8268b3cd02ef9[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 19:44:35 2024 +1000
|
||||||
|
|
||||||
|
renamed files
|
||||||
|
|
||||||
|
[33mcommit 91c5d02a72d07639c2a1fc97443fd4409507f529[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 19:44:11 2024 +1000
|
||||||
|
|
||||||
|
renamed files
|
||||||
|
|
||||||
|
[33mcommit be2edde8e64a4b5acaf38952b60f1f386c6389a3[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 19:37:25 2024 +1000
|
||||||
|
|
||||||
|
modified backup directory
|
||||||
|
|
||||||
|
[33mcommit b1703854ea43cfc9d16416d08bd98204f02444b5[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Mon Oct 28 19:31:02 2024 +1000
|
||||||
|
|
||||||
|
Added apt update, moved old scripts
|
||||||
|
|
||||||
|
[33mcommit ed02b14f7478fa565454800ecda8d404357ae5fb[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 17:00:13 2024 +1000
|
||||||
|
|
||||||
|
Created backup script for docker1. Changed wording
|
||||||
|
|
||||||
|
[33mcommit 9e37189a28228b0e4c5d06fdb3d7be4973345aca[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 15:13:57 2024 +1000
|
||||||
|
|
||||||
|
added postfix smtp
|
||||||
|
|
||||||
|
[33mcommit cd74483e94bdd20df7a4fe0be815358833e6dce2[m
|
||||||
|
Author: rgmcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 14:41:32 2024 +1000
|
||||||
|
|
||||||
|
new script with confirmation email
|
||||||
|
|
||||||
|
[33mcommit 9616c2ebe566399eaf83bc35f0ca8b7c36413688[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 02:22:32 2024 +0000
|
||||||
|
|
||||||
|
Update docker2-backup.sh
|
||||||
|
|
||||||
|
[33mcommit d02c658c997280b5b48b060524b0a7c8e0e290fb[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 02:18:02 2024 +0000
|
||||||
|
|
||||||
|
Update docker1-backup.sh
|
||||||
|
|
||||||
|
[33mcommit 52d78f02b3ea2c1d6f07e74f79d98dfe33ba8fff[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 01:50:18 2024 +0000
|
||||||
|
|
||||||
|
Update docker1-backup.sh
|
||||||
|
|
||||||
|
[33mcommit f8f29dcd2f1f318d2f21262ff6b07f3b022b849b[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 01:42:30 2024 +0000
|
||||||
|
|
||||||
|
Add docker1-backup.sh
|
||||||
|
|
||||||
|
Must be run as sudo
|
||||||
|
|
||||||
|
[33mcommit 555af6499f9cc928b5a87979e4dc4d93e23df448[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Sat Oct 26 01:40:33 2024 +0000
|
||||||
|
|
||||||
|
Add docker2-backup.sh
|
||||||
|
|
||||||
|
Stops all docker containers and backs up the /docker directory to BackBlaze using rclone. Rclone must be configured separately using <code>sudo rclone config</code>
|
||||||
|
|
||||||
|
(MUST BE RUN AS SUDO)
|
||||||
|
|
||||||
|
[33mcommit d1b15fb7ac2b010d39ca40a4088ddf1e6f12433e[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Oct 25 13:12:58 2024 +0000
|
||||||
|
|
||||||
|
Update send-output-as-email-llama.sh
|
||||||
|
|
||||||
|
[33mcommit d1960744352e09680521500444af48517cbd4761[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Oct 25 13:11:57 2024 +0000
|
||||||
|
|
||||||
|
Update sendoutputasemail-llama.sh
|
||||||
|
|
||||||
|
llama3:8b
|
||||||
|
|
||||||
|
Here is a simple bash script that displays a string of text and sends the full output of the script as an email:
|
||||||
|
|
||||||
|
Let me explain what each part of the script does:
|
||||||
|
|
||||||
|
The first two echo statements display a string of text and a separator line.
|
||||||
|
The OUTPUT=$(cat /dev/null) command uses command substitution to capture the output of the script as a variable. In this case, we're capturing nothing (since /dev/null is an empty file).
|
||||||
|
The mail -s "Test Email from Bash Script" recipient@example.com << EOF command sends an email using the mailx utility (or your preferred MTA). The -s option sets the subject line of the email.
|
||||||
|
The << EOF syntax starts a here document, which allows us to embed the email body within the script. The $OUTPUT variable is expanded to contain the output of the script, which is sent as the email body.
|
||||||
|
To use this script, simply save it to a file (e.g., send_email.sh) and make the file executable with the command chmod +x send_email.sh. Then, run the script using the command ./send_email.sh, replacing recipient@example.com with the actual email address you want to send the message to.
|
||||||
|
|
||||||
|
Note: This script assumes that you have the mailx utility installed on your system. If you don't have it, you can install it or use an alternative MTA like sendmail or smtplib.
|
||||||
|
|
||||||
|
[33mcommit 301cbde5d8c37926a951ccacd7c6082c43b4cb6f[m
|
||||||
|
Author: rob.mcewan <rgmcewan@outlook.com>
|
||||||
|
Date: Fri Oct 25 13:10:26 2024 +0000
|
||||||
|
|
||||||
|
Add sendoutputasemail.sh
|
Loading…
Reference in a new issue