librechat: add jwt tokens
This commit is contained in:
parent
f97186cefc
commit
d038353260
2 changed files with 15 additions and 3 deletions
|
|
@ -6,7 +6,6 @@
|
|||
}:
|
||||
|
||||
let
|
||||
inherit (constants) domain;
|
||||
inherit (constants.hosts.rx4) ip;
|
||||
inherit (constants.services.librechat-oci) fqdn port;
|
||||
in
|
||||
|
|
@ -19,6 +18,7 @@ in
|
|||
enable = true;
|
||||
inherit port;
|
||||
externalUrl = "https://${fqdn}";
|
||||
environmentFile = config.sops.templates.librechat-env-file.path;
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."${fqdn}" = {
|
||||
|
|
@ -41,4 +41,13 @@ in
|
|||
postRun = "systemctl restart podman-librechat.service";
|
||||
group = "nginx";
|
||||
};
|
||||
|
||||
sops = {
|
||||
secrets."librechat/jwt-token" = { }; # openssl rand -hex 32
|
||||
secrets."librechat/jwt-refresh-token" = { }; # openssl rand -hex 32
|
||||
templates.librechat-env-file.content = ''
|
||||
JET_TOKEN=${config.sops.placeholder."librechat/jwt-token"}
|
||||
JET_REFRESH_TOKEN=${config.sops.placeholder."librechat/jwt-refresh-token"}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue