diff options
author | Timo Wilken | 2023-04-21 22:20:23 +0200 |
---|---|---|
committer | Timo Wilken | 2023-04-21 23:17:25 +0200 |
commit | 73f2af2846ccba77d94af10a620dbf37bd19be3a (patch) | |
tree | ba1eeff1477257af6dadaec80fd3bed7def2ee1c /tw/home | |
parent | c2712ba27ea8cc26166d9a074a0ba8bd528c8462 (diff) |
Configure restic environment
Diffstat (limited to 'tw/home')
-rw-r--r-- | tw/home/files/zshrc | 3 | ||||
-rw-r--r-- | tw/home/lap.scm | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/tw/home/files/zshrc b/tw/home/files/zshrc index 2382fa27..1d666f70 100644 --- a/tw/home/files/zshrc +++ b/tw/home/files/zshrc @@ -97,6 +97,9 @@ alias cdiff='\diff -s --color=always' alias ipy='ipython3 --autoindent --automagic --pprint --no-banner --no-confirm-exit --term-title --autocall=1 --colors=Neutral' alias rot13='caesar 13' alias wget='\wget --hsts-file="${XDG_CACHE_HOME:-$HOME/.cache}/wget-hsts"' +# Set RESTIC_REPOSITORY here, since we have to run pass(1) to generate it. +# RESTIC_PASSWORD_COMMAND is set separately, since it's a static string that restic will execute. +alias restic='RESTIC_REPOSITORY="rest:http://timo:$(pass computers/vin/restic-server/timo | head -1)@vin.wg:8181/timo/laptop" \restic' alias aurora="REQUESTS_CA_BUNDLE=${XDG_CONFIG_HOME:-$HOME/.config}/cern-ca-bundle.crt \aurora" alias aurora_admin="REQUESTS_CA_BUNDLE=${XDG_CONFIG_HOME:-$HOME/.config}/cern-ca-bundle.crt \aurora_admin" alias nomad='NOMAD_TOKEN=$(pass cern/ci/nomad-bootstrap-token | head -1) \nomad' diff --git a/tw/home/lap.scm b/tw/home/lap.scm index c2ce6fa7..962e378f 100644 --- a/tw/home/lap.scm +++ b/tw/home/lap.scm @@ -119,6 +119,9 @@ (home-batsignal-configuration (batteries '("BAT0")))) + (simple-service 'restic-environment home-environment-variables-service-type + `(("RESTIC_PASSWORD_COMMAND" . "pass computers/vin/restic-repos/laptop"))) + ;; Redshift: make the screen turn redder at night. (service home-redshift-service-type (home-redshift-configuration |