mirror of
https://git.selfprivacy.org/SelfPrivacy/selfprivacy-nixos-config.git
synced 2024-11-27 05:11:30 +00:00
Read value directly from json
This commit is contained in:
parent
2d26ca545e
commit
41187bb18f
|
@ -5,7 +5,7 @@ in
|
||||||
{
|
{
|
||||||
systemd.tmpfiles.rules =
|
systemd.tmpfiles.rules =
|
||||||
let
|
let
|
||||||
nextcloudDBPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.nextcloud.databasePassword;
|
nextcloudDBPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] (builtins.fromJSON (builtins.readFile ./userdata/userdata.json).nextcloud.databasePassword);
|
||||||
nextcloudAdminPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.nextcloud.adminPassword;
|
nextcloudAdminPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.nextcloud.adminPassword;
|
||||||
resticPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.resticPassword;
|
resticPass = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.resticPassword;
|
||||||
domain = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.domain;
|
domain = builtins.replaceStrings [ "\n" "\"" "\\" "%" ] [ "\\n" "\\\"" "\\\\" "%%" ] cfg.domain;
|
||||||
|
|
|
@ -141,12 +141,12 @@ in
|
||||||
default = true;
|
default = true;
|
||||||
type = types.nullOr types.bool;
|
type = types.nullOr types.bool;
|
||||||
};
|
};
|
||||||
databasePassword = mkOption {
|
# databasePassword = mkOption {
|
||||||
description = ''
|
# description = ''
|
||||||
Password for the nextcloud database
|
# Password for the nextcloud database
|
||||||
'';
|
# '';
|
||||||
type = types.nullOr types.str;
|
# type = types.nullOr types.str;
|
||||||
};
|
# };
|
||||||
adminPassword = mkOption {
|
adminPassword = mkOption {
|
||||||
description = ''
|
description = ''
|
||||||
Password for the nextcloud admin user
|
Password for the nextcloud admin user
|
||||||
|
|
Loading…
Reference in a new issue