cluster/services/patroni: implement raw format for locksmith provider
This commit is contained in:
parent
570fd69928
commit
d8d1ece5ec
2 changed files with 5 additions and 1 deletions
|
@ -79,6 +79,10 @@ in
|
||||||
echo "*:*:*:${user}:$(cat /run/keys/locksmith-provider-patroni-${user})"
|
echo "*:*:*:${user}:$(cat /run/keys/locksmith-provider-patroni-${user})"
|
||||||
rm -f /run/keys/locksmith-provider-patroni-${user}
|
rm -f /run/keys/locksmith-provider-patroni-${user}
|
||||||
'';
|
'';
|
||||||
|
raw = ''
|
||||||
|
cat /run/keys/locksmith-provider-patroni-${user}
|
||||||
|
rm -f /run/keys/locksmith-provider-patroni-${user}
|
||||||
|
'';
|
||||||
}.${userConfig.locksmith.format};
|
}.${userConfig.locksmith.format};
|
||||||
checkUpdate = "test -e /run/keys/locksmith-provider-patroni-${user}";
|
checkUpdate = "test -e /run/keys/locksmith-provider-patroni-${user}";
|
||||||
inherit (userConfig.locksmith) nodes;
|
inherit (userConfig.locksmith) nodes;
|
||||||
|
|
|
@ -26,7 +26,7 @@ in
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
format = mkOption {
|
format = mkOption {
|
||||||
type = enum [ "pgpass" "envFile" ];
|
type = enum [ "pgpass" "envFile" "raw" ];
|
||||||
default = "pgpass";
|
default = "pgpass";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue