What is this?
A Simple program to automatically backup a database using git.
go get github.com/joshhhhyyyy/backup
go install github.com/joshhhhyyyy/backup
export PATH=$PATH:$(go env GOPATH)/bin (Add gopath to path)
echo "deb [trusted=yes] https://apt.joseos.com/ ./" | sudo tee /etc/apt/sources.list.d/joseos.list
sudo apt update
sudo apt install backup
Basically, systemd timers is a great alternative to cronjobs as it can be invoked and controlled via systemctl.
Every timer has a corresponding service file that it invokes when the time specified is hit. In the sample files provided, the timer triggers a backup at 4am and 59seconds daily.
This program can also be run manually with the command, where you can specify the commit message as well
**note: both single minus "-" and double minus "--" work fine
-key="" // Required, Type: string, Sentry.io dsn (key url) for project
-bup="" // Optional, Type: string, betteruptime heartbeat url, eg. "https://betteruptime.com/api/v1/~~~"
-message="" // Not needed at all, Type: string, optional commit message to pass for manual runs