db reindex

This commit is contained in:
soraefir
2026-06-05 19:31:45 +02:00
parent 5ee625cc89
commit 0531cfb361

View File

@@ -98,6 +98,7 @@ in {
PSQL="${pkgs.postgresql}/bin/psql"
${lib.concatMapStringsSep "\n" (name: ''
$PSQL -tAc "ALTER DATABASE ${name}_db OWNER TO ${name}_user;"
$PSQL -tAc "REINDEX DATABASE ${name}_db;"
if [ -f "${config.sops.secrets."${lib.toUpper name}".path}" ]; then
PASS=$(grep "^DB_PASSWORD=" "${config.sops.secrets."${lib.toUpper name}".path}" | cut -d'=' -f2-)