This repository has no description
1.1 kB
32 lines
1{ config, pkgs, ... }:
2{
3 krebs.sync-containers3.containers.orange = {
4 sshKey = config.clan.core.vars.generators.orange-container.files."orange.sync.key".path;
5 startCommand = ''
6 export PATH=$PATH:${pkgs.git}/bin
7 until ${pkgs.dig.host}/bin/host github.com; do sleep 1; done
8 ${pkgs.nixos-rebuild}/bin/nixos-rebuild --refresh --flake github:lassulus/superconfig#orange switch --no-write-lock-file
9 '';
10 };
11 containers.orange.bindMounts."/var/lib" = {
12 hostPath = "/var/lib/sync-containers3/orange/state";
13 isReadOnly = false;
14 };
15 services.nginx.virtualHosts."lassul.us" = {
16 # enableACME = config.security;
17 # forceSSL = true;
18 locations."/" = {
19 recommendedProxySettings = true;
20 proxyWebsockets = true;
21 proxyPass = "http://orange.r";
22 };
23 };
24 clan.core.vars.generators.orange-container = {
25 files."orange.sync.key" = { };
26 migrateFact = "orange-container";
27 prompts.warn = {
28 description = "copy or reference the secret key from the container into here, so we can actually start/sync the container";
29 type = "hidden";
30 };
31 };
32}