Compare commits
2 Commits
91632cab51
...
09f8b20018
| Author | SHA1 | Date | |
|---|---|---|---|
| 09f8b20018 | |||
| c76c7cc981 |
5
Makefile
5
Makefile
@@ -70,6 +70,11 @@ destroy: ignition.json $(config_dir)$(TERRAFORM_ENV).tfvars generated.tfvars
|
|||||||
restic-init: $(apps_config) restic-password
|
restic-init: $(apps_config) restic-password
|
||||||
./init-restic.sh $(apps_config)
|
./init-restic.sh $(apps_config)
|
||||||
|
|
||||||
|
## just an easy way to see snapshots that have been taken
|
||||||
|
.PHONY: restic-snapshots
|
||||||
|
restic-snapshots: $(apps_config) restic-password
|
||||||
|
./restic-snapshots.sh $(apps_config)
|
||||||
|
|
||||||
## to help me remember the command to run to test the config locally
|
## to help me remember the command to run to test the config locally
|
||||||
testlocalhost:
|
testlocalhost:
|
||||||
curl -k --resolve localhost:443:146.190.12.129 https://localhost
|
curl -k --resolve localhost:443:146.190.12.129 https://localhost
|
||||||
|
|||||||
1
cl.yaml
1
cl.yaml
@@ -35,6 +35,7 @@ systemd:
|
|||||||
ExecStopPost=systemctl start app.service
|
ExecStopPost=systemctl start app.service
|
||||||
|
|
||||||
- name: restic-backup.timer
|
- name: restic-backup.timer
|
||||||
|
enabled: true
|
||||||
contents: |
|
contents: |
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Run restic-backup.service at 3am PT
|
Description=Run restic-backup.service at 3am PT
|
||||||
|
|||||||
7
restic-snapshots.sh
Executable file
7
restic-snapshots.sh
Executable file
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
. $1 # source the apps.config file with then env vars
|
||||||
|
|
||||||
|
docker run --rm --volume $PWD/restic-password:/restic-password -e AWS_ACCESS_KEY_ID="$BACKBLAZE_KEY_ID" -e AWS_SECRET_ACCESS_KEY="$BACKBLAZE_APPLICATION_KEY" -i restic/restic:0.18.0 snapshots --repo s3:$BACKBLAZE_BUCKET_URL --password-file /restic-password
|
||||||
Reference in New Issue
Block a user