services: gitea: ensure database exists
This commit is contained in:
parent
ee549958d1
commit
a21de59c5d
|
@ -95,6 +95,18 @@ in {
|
|||
];
|
||||
};
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
|
||||
ensureDatabases = ["gitea"];
|
||||
ensureUsers = [
|
||||
{
|
||||
name = "git";
|
||||
ensurePermissions."DATABASE gitea" = "ALL PRIVILEGES";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
services.postgresqlBackup = {
|
||||
databases = ["gitea"];
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue