summaryrefslogtreecommitdiff
path: root/src/push-btrfs.service
diff options
context:
space:
mode:
Diffstat (limited to 'src/push-btrfs.service')
-rw-r--r--src/push-btrfs.service15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/push-btrfs.service b/src/push-btrfs.service
index 7d32080..c4ab87c 100644
--- a/src/push-btrfs.service
+++ b/src/push-btrfs.service
@@ -5,13 +5,14 @@ ConditionPathExistsGlob = /etc/btrfs-backup/remotes/*.json
5 5
6[Service] 6[Service]
7WorkingDirectory = /etc/btrfs-backup/remotes 7WorkingDirectory = /etc/btrfs-backup/remotes
8ExecStart = bash -e -c 'shopt -s failglob; \ 8ExecStart = bash -e -c '\
9 units=(*.json); \ 9shopt -s failglob; \
10 units=($${units[@]/.json/.timer}); \ 10units=(*.json); \
11 units=($${units[@]/#/%p@}); \ 11units=($${units[@]/.json/.timer}); \
12 systemctl enable "$${units[@]}"; \ 12units=($${units[@]/#/%p@}); \
13 entr -pnd -- true <<< . || true; \ 13systemctl enable --now "$${units[@]}"; \
14 ' 14entr -pnd -- true <<< . || true; \
15'
15 16
16[Install] 17[Install]
17WantedBy=default.target 18WantedBy=default.target