Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d01d2995f5 | ||
|
|
97a9475550 | ||
|
|
2e55d1cfef | ||
|
|
7a8861adc4 | ||
|
|
bf9b29575a | ||
|
|
428f4be872 | ||
|
|
99f4ba4436 | ||
|
|
ae2b122134 | ||
|
|
8e1853458c |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,2 +1,3 @@
|
||||
# Prevent check-in of these sensitive files. Instead they are generated from the corresponding *.template file.
|
||||
/etc/restic/b2_pw.txt
|
||||
/etc/restic/b2_env.sh
|
||||
|
||||
@@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
## [1.0.1] - 2021-12-03
|
||||
### Fixed
|
||||
- $(make install) now works for the *.template files ([#40](https://github.com/erikw/restic-systemd-automatic-backup/issues/40))
|
||||
|
||||
## [1.0.0] - 2021-12-02
|
||||
It's time to call this a proper major version!
|
||||
|
||||
|
||||
14
Makefile
14
Makefile
@@ -3,7 +3,7 @@
|
||||
|
||||
### Macros ###
|
||||
SRCS_SCRIPTS = $(filter-out %cron_mail, $(wildcard usr/local/sbin/*))
|
||||
SRCS_CONF = $(filter-out %template, $(wildcard etc/restic/*))
|
||||
SRCS_CONF = $(patsubst %.template, %, $(wildcard etc/restic/*))
|
||||
SRCS_SYSTEMD = $(wildcard etc/systemd/system/*)
|
||||
|
||||
# Just set PREFIX in envionment, like
|
||||
@@ -32,15 +32,15 @@ install-scripts:
|
||||
install -d $(DEST_SCRIPTS)
|
||||
install -m 0744 $(SRCS_SCRIPTS) $(DEST_SCRIPTS)
|
||||
|
||||
etc/restic/b2_env.sh:
|
||||
install -m 0600 etc/restic/b2_env.sh.template /etc/restic/b2_env.sh
|
||||
|
||||
etc/restic/b2_pw.txt:
|
||||
install -m 0600 etc/restic/b2_pw.txt.template /etc/restic/b2_pw.txt
|
||||
# Copy templates to new files with restricted permissions.
|
||||
# Why? Because the non-template files are git-ignored to preovent that someone who clones or forks this repo checks in their sensitive data like the B2 password!
|
||||
etc/restic/b2_env.sh etc/restic/b2_pw.txt:
|
||||
install -m 0600 $@.template $@
|
||||
|
||||
# target: install-conf - Install restic configuration files.
|
||||
# will create these files locally only if they don't already exist
|
||||
install-conf: | etc/restic/b2_env.sh etc/restic/b2_pw.txt
|
||||
# | means that dependencies are order-ony i.e. only created if they don't already exist.
|
||||
install-conf: | $(SRCS_CONF)
|
||||
install -d $(DEST_CONF)
|
||||
install -m 0600 $(SRCS_CONF) $(DEST_CONF)
|
||||
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
[](#)
|
||||
[](#)
|
||||
<br>
|
||||
[](https://aur.archlinux.org/packages/restic-systemd-automatic-backup/)
|
||||
[](https://aur.archlinux.org/packages/restic-systemd-automatic-backup/)
|
||||
[](#)
|
||||
[](https://github.com/erikw/restic-systemd-automatic-backup/issues)
|
||||
[](https://github.com/erikw/restic-systemd-automatic-backup/issues?q=is%3Aissue+is%3Aclosed)
|
||||
@@ -40,6 +42,11 @@ $ cd restic-systemd-automatic-backup
|
||||
$ sudo make install
|
||||
````
|
||||
|
||||
Arch Linux users can install the aur package [restic-systemd-automatic-backup](https://aur.archlinux.org/packages/restic-systemd-automatic-backup/) e.g. :
|
||||
```console
|
||||
$ yaourt -S restic-systemd-automatic-backup
|
||||
````
|
||||
|
||||
## 1. Create Backblaze B2 account
|
||||
|
||||
First, see this official Backblaze [tutorial](https://help.backblaze.com/hc/en-us/articles/115002880514-How-to-configure-Backblaze-B2-with-Restic-on-Linux) on restic, and follow the instructions ("Create Backblaze account with B2 enabled") there on how to create a new B2 bucket.
|
||||
|
||||
Reference in New Issue
Block a user