diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..d879766 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,25 @@ +name: run-tests + +on: + pull_request: + branches: + - main + push: + branches: + - main + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Run moi ça… + uses: addnab/docker-run-action@v3 + with: + image: nixos/nix + options: --privileged -v ${{ github.workspace }}:/workspace + run: | + cp /workspace /tmp/workspace -r + chown root: /tmp/workspace -R + cd /tmp/workspace + nix --extra-experimental-features nix-command --extra-experimental-features flakes develop --command bash -c 'nixunits build TOTO -cc "{ services.httpd.enable = true; }" -6' diff --git a/src/nixunits.nix b/src/nixunits.nix index 9102fb2..87a24f8 100644 --- a/src/nixunits.nix +++ b/src/nixunits.nix @@ -34,7 +34,7 @@ stdenv.mkDerivation rec { platforms = platforms.linux; maintainers = [ maintainers.evoo ]; }; - nativeBuildInputs = with pkgs; [ jq ]; + nativeBuildInputs = with pkgs; [ jq util-linux ]; # phases = ["buildPhase"]; }