nixos: services: migrate to 'ensureDBOwnership'
All checks were successful
ci/woodpecker/push/check Pipeline was successful

`ensurePermissions` is deprecated, and doesn't work on PostgreSQL 15.
This commit is contained in:
Bruno BELANYI 2023-11-21 00:18:29 +01:00
parent 60d941b40b
commit b48d81451d
7 changed files with 7 additions and 11 deletions

View file

@ -41,9 +41,7 @@ in
ensureDatabases = [ "drone" ]; ensureDatabases = [ "drone" ];
ensureUsers = [{ ensureUsers = [{
name = "drone"; name = "drone";
ensurePermissions = { ensureDBOwnership = true;
"DATABASE drone" = "ALL PRIVILEGES";
};
}]; }];
}; };

View file

@ -57,7 +57,7 @@ in
ensureUsers = [ ensureUsers = [
{ {
name = "nextcloud"; name = "nextcloud";
ensurePermissions."DATABASE nextcloud" = "ALL PRIVILEGES"; ensureDBOwnership = true;
} }
]; ];
}; };

View file

@ -131,7 +131,7 @@ in
ensureUsers = [ ensureUsers = [
{ {
name = "paperless"; name = "paperless";
ensurePermissions."DATABASE paperless" = "ALL PRIVILEGES"; ensureDBOwnership = true;
} }
]; ];
}; };

View file

@ -39,7 +39,7 @@ in
ensureUsers = [ ensureUsers = [
{ {
name = "quassel"; name = "quassel";
ensurePermissions."DATABASE quassel" = "ALL PRIVILEGES"; ensureDBOwnership = true;
} }
]; ];
# Insecure, I don't care. # Insecure, I don't care.

View file

@ -65,7 +65,7 @@ in
ensureUsers = [ ensureUsers = [
{ {
name = "tandoor_recipes"; name = "tandoor_recipes";
ensurePermissions."DATABASE tandoor_recipes" = "ALL PRIVILEGES"; ensureDBOwnership = true;
} }
]; ];
}; };

View file

@ -109,7 +109,7 @@ in
ensureUsers = [ ensureUsers = [
{ {
name = "vikunja"; name = "vikunja";
ensurePermissions = { "DATABASE vikunja" = "ALL PRIVILEGES"; }; ensureDBOwnership = true;
} }
]; ];
}; };

View file

@ -48,9 +48,7 @@ in
ensureDatabases = [ "woodpecker" ]; ensureDatabases = [ "woodpecker" ];
ensureUsers = [{ ensureUsers = [{
name = "woodpecker"; name = "woodpecker";
ensurePermissions = { ensureDBOwnership = true;
"DATABASE woodpecker" = "ALL PRIVILEGES";
};
}]; }];
}; };