Ensure we have an app secret set, also after update

This commit is contained in:
Johannes Zellner 2022-12-14 15:58:24 +01:00
parent 8543ac28e0
commit e86ace516f

View file

@ -41,6 +41,11 @@ first_time_setup() {
update_config() {
echo "==> Ensure and updating configs"
# version 5 needs this now
if [[ `yq eval '.secrets | has("peertube")' /app/data/production.yaml` != "true" ]]; then
yq eval ".secrets.peertube = \"`openssl rand -hex 32`\"" -i /app/data/production.yaml
fi
yq eval ".webserver.hostname = \"${CLOUDRON_APP_DOMAIN}\"" -i /app/data/production.yaml
# database