diff --git a/.gitea/workflows/check-flake.yaml b/.gitea/workflows/check-flake.yaml index bd68862..70d653b 100644 --- a/.gitea/workflows/check-flake.yaml +++ b/.gitea/workflows/check-flake.yaml @@ -10,10 +10,6 @@ jobs: check-flake: runs-on: nixos steps: - - - name: Install dependencies - run: nix profile install nixpkgs#nodejs-18_x - - name: Checkout the repository uses: actions/checkout@v3 with: diff --git a/common/server/gitea-actions-runner.nix b/common/server/gitea-actions-runner.nix index 08d96ce..2a63cf7 100644 --- a/common/server/gitea-actions-runner.nix +++ b/common/server/gitea-actions-runner.nix @@ -1,4 +1,4 @@ -{ config, pkgs, lib, ... }: +{ config, pkgs, lib, allModules, ... }: # Gitea Actions Runner. Starts 'host' runner that runs directly on the host inside of a nixos container # This is useful for providing a real Nix/OS builder to gitea. @@ -12,7 +12,7 @@ let thisMachineIsARunner = builtins.elem config.networking.hostName runners; in { - config = lib.mkIf thisMachineIsARunner { + config = lib.mkIf (thisMachineIsARunner && !config.boot.isContainer) { containers.gitea-runner = { ephemeral = true; autoStart = true; @@ -35,15 +35,15 @@ in ]; config = { - # TODO: figure out why importing 'allModules' fails - # imports = allModules; + imports = allModules; # speeds up evaluation nixpkgs.pkgs = pkgs; environment.systemPackages = with pkgs; [ - nodejs git + # Gitea Actions rely heavily on node. Include it because it would be installed anyway. + nodejs ]; services.gitea-actions-runner.instances.inst = { @@ -59,8 +59,6 @@ in virtualisation.podman.enable = true; boot.binfmt.emulatedSystems = [ "aarch64-linux" ]; - - system.stateVersion = "23.05"; }; };