new librechat api
Some checks failed
Build hosts / build-hosts (pull_request) Failing after 1s
Flake check / flake-check (pull_request) Failing after 1s

This commit is contained in:
sid 2026-05-19 20:59:18 +02:00
parent d038353260
commit afb49c7407
3 changed files with 37 additions and 12 deletions

View file

@ -18,7 +18,16 @@ in
enable = true;
inherit port;
externalUrl = "https://${fqdn}";
environmentFile = config.sops.templates.librechat-env-file.path;
# environment = {
# ALLOW_REGISTRATION = "true";
# };
environmentFiles = {
librechat = config.sops.templates.librechat-env.path;
meilisearch = config.sops.templates.meili-env.path;
ragApi = null;
};
};
services.nginx.virtualHosts."${fqdn}" = {
@ -43,11 +52,24 @@ in
};
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"}
# generate with:
# openssl rand -hex 32
secrets."librechat/jwt-secret" = { };
secrets."librechat/jwt-refresh-secret" = { };
secrets."librechat/creds-key" = { };
secrets."librechat/creds-iv" = { };
secrets."librechat/meili-master-key" = { };
templates.librechat-env.content = ''
JWT_SECRET=${config.sops.placeholder."librechat/jwt-secret"}
JWT_REFRESH_SECRET=${config.sops.placeholder."librechat/jwt-refresh-secret"}
CREDS_KEY=${config.sops.placeholder."librechat/creds-key"}
CREDS_IV=${config.sops.placeholder."librechat/creds-iv"}
MEILI_MASTER_KEY=${config.sops.placeholder."librechat/meili-master-key"}
'';
templates.meili-env.content = ''
MEILI_MASTER_KEY=${config.sops.placeholder."librechat/meili-master-key"}
'';
};
}