From 5eb2e69fd82ca442afbdca6cda698bf6c4599afd Mon Sep 17 00:00:00 2001 From: dusk Date: Mon, 14 Jul 2025 03:55:07 +0300 Subject: [PATCH] process-compose.yaml: add for starting up local dev env using nix --- process-compose.yaml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 process-compose.yaml diff --git a/process-compose.yaml b/process-compose.yaml new file mode 100644 index 0000000..d11c7fd --- /dev/null +++ b/process-compose.yaml @@ -0,0 +1,35 @@ +env_cmds: + OAUTH_JWKS: "nix run .#genjwks" + +processes: + redis: + command: nix shell nixpkgs#redis -c redis-server + description: "run redis server" + restart: on_failure + ready_log_line: "Ready to accept connections" + + watch-tailwind: + command: nix run .#watch-tailwind + description: "watch and rebuild tailwind css" + is_tty: true # needed because tailwindcss expects a tty + restart: on_failure + ready_log_line: "Done in " + + vm: + command: nix run .#vm + description: "run knot, spindle, ssh, etc." + restart: on_failure + ready_log_line: "nixos login: root (automatic login)" + + watch-appview: + command: TANGLED_DEV=true TANGLED_OAUTH_JWKS=$${OAUTH_JWKS} nix run .#watch-appview + description: "watch and rebuild app view" + restart: on_failure + ready_log_line: "running..." + depends_on: + watch-tailwind: + condition: process_log_ready + vm: + condition: process_log_ready + redis: + condition: process_log_ready -- 2.43.0 From 35b0fdc33244e3477f204782a0a720e1bca79693 Mon Sep 17 00:00:00 2001 From: dusk Date: Mon, 14 Jul 2025 04:02:31 +0300 Subject: [PATCH] flake.nix: add app for starting up process-compose --- flake.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/flake.nix b/flake.nix index d01c9f7..d53ca8c 100644 --- a/flake.nix +++ b/flake.nix @@ -188,6 +188,10 @@ ${gomod2nix.legacyPackages.${system}.gomod2nix}/bin/gomod2nix generate --outdir ./nix ''); }; + dev-compose = { + type = "app"; + program = "${pkgs.process-compose}/bin/process-compose"; + }; }); nixosModules.appview = { -- 2.43.0