From 0bb5df72451b466c386358e98b27669a2efea904 Mon Sep 17 00:00:00 2001 From: Miguel Palhas Date: Mon, 24 Aug 2026 16:19:01 +0100 Subject: [PATCH] fix(maestro): write nix.conf before installing nix in CI The runner container is root with no `nixbld` group. The installer writes `build-users-group = nixbld` regardless and then fails on it: error: the group 'nixbld' specified in 'build-users-group' does not exist Writing the config first (and again after, in case the installer replaced it) clears that and enables flakes in the same place. Refs #98 --- .gitea/workflows/ci.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 297c85f..978d2b2 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -106,11 +106,16 @@ jobs: steps: - uses: actions/checkout@v4 - # Single-user install: the runner is a container with no systemd, and - # the --daemon installer refuses without it. + # The runner container is root with no `nixbld` group, but the installer + # writes `build-users-group = nixbld` anyway and then fails on it, so the + # config goes in first. Flakes are off by default and `nix build .#…` + # needs them. Written again afterwards in case the installer replaced it. - name: Install nix run: | + mkdir -p /etc/nix + printf 'build-users-group =\nexperimental-features = nix-command flakes\n' > /etc/nix/nix.conf curl -fsSL https://nixos.org/nix/install | sh -s -- --no-daemon --yes + printf 'build-users-group =\nexperimental-features = nix-command flakes\n' > /etc/nix/nix.conf echo "$HOME/.nix-profile/bin" >> "$GITHUB_PATH" # The installer does not enable flakes, so `nix build .#…` needs the