{ config, pkgs, ... }: let inherit (import ../lib.nix config) blazestar; db_password = "wargame-vods/db/password"; admin_token = "wargame-vods/admin-token"; in { sops = { secrets = { "${db_password}" = { }; "${admin_token}" = { }; }; templates."wargame-vods.env" = { mode = "0400"; content = '' ADMIN_TOKEN=${config.sops.placeholder."${admin_token}"} PGHOST=db PGPORT=5432 PGUSER=wargame-vods PGPASS=${config.sops.placeholder."${db_password}"} PGDATABASE=wargame-vods STATIC_DIR=/app/static PORT=8081 SSL_CERT_FILE=${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt ''; }; }; virtualisation.web-containers.containers.wargame-vods = { image = "docker.havenisms.com/apps/wargame-vods"; hostname = "vods"; domain = blazestar; port = 8081; volumes = [ ]; dependsOn = [ "db" ]; environmentFiles = [ config.sops.templates."wargame-vods.env".path ]; }; }