Reworked for simplified flake
This commit is contained in:
parent
f55936312f
commit
d3eddb7445
7 changed files with 234 additions and 96 deletions
19
modules/postgresql/default.nix
Normal file
19
modules/postgresql/default.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{ config, lib, pkgs, specialConfig, ... }:
|
||||
{
|
||||
# Disable local postgres (so NixOS won't start or manage it)
|
||||
services = {
|
||||
postgresql = {
|
||||
enable = true;
|
||||
ensureDatabases = [ "nbxplorermainnet" "btcpaydb" ];
|
||||
ensureUsers = [
|
||||
{ name = "nbxplorer"; ensureDBOwnership = true; }
|
||||
{ name = "btcpay"; ensureDBOwnership = true; }
|
||||
];
|
||||
authentication = ''
|
||||
local all all trust
|
||||
host all all 0.0.0.1/32 trust
|
||||
host all all ::1/128 trust
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue