Adapt vault cleanups

This commit is contained in:
Daniel Berteaud 2024-01-31 11:15:14 +01:00
parent 4f6829a4d0
commit 4d1a5f8786
5 changed files with 5 additions and 28 deletions

View File

@ -1,19 +0,0 @@
#!/bin/sh
set -eu
if [ "vaultwarden" != "vaultwarden" ]; then
for DIR in vault consul nomad; do
if [ -d output/${DIR} ]; then
for FILE in $(find output/${DIR} -name "*vaultwarden*.hcl" -type f); do
NEW_FILE=$(echo "${FILE}" | sed -E "s/vaultwarden/vaultwarden/g")
mv "${FILE}" "${NEW_FILE}"
done
fi
done
fi

5
init/vault-database Executable file
View File

@ -0,0 +1,5 @@
#!/bin/sh
set -euo pipefail
[[ template "common/vault.mkpgrole.sh.tpl" merge .vaultwarden.server . ]]

View File

@ -1,8 +0,0 @@
#!/bin/sh
set -euo pipefail
[[- template "common/vault.mkpgrole.sh.tpl"
dict "ctx" .
"config" (dict "role" .instance "database" "postgres")
]]

View File

@ -1 +0,0 @@
[[ template "common/mv_conf.sh" dict "ctx" . "services" (dict "vaultwarden" .instance) ]]