mirror of
https://github.com/Mic92/sops-nix.git
synced 2024-12-14 11:57:52 +00:00
ci: add macOS support
This commit is contained in:
parent
3095053dd4
commit
8c33651e0c
1 changed files with 8 additions and 5 deletions
13
.github/workflows/test.yml
vendored
13
.github/workflows/test.yml
vendored
|
@ -11,7 +11,8 @@ jobs:
|
|||
nixPath:
|
||||
- nixpkgs=channel:nixos-20.03
|
||||
- nixpkgs=channel:nixpkgs-unstable
|
||||
runs-on: ubuntu-latest
|
||||
os: [ ubuntu-latest, macos-latest ]
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: cachix/install-nix-action@v10
|
||||
|
@ -29,9 +30,11 @@ jobs:
|
|||
if: matrix.nixPath == 'nixpkgs=channel:nixpkgs-unstable'
|
||||
- name: Build nix packages
|
||||
run: nix run nixpkgs.nix-build-uncached -c nix-build-uncached default.nix
|
||||
- name: Add keys group (needed for go tests)
|
||||
run: sudo groupadd keys
|
||||
- name: Run sops-install-secrets tests
|
||||
run: nix-shell --pure --run "$(command -v sudo) unshare --mount --fork go test ./pkgs/sops-install-secrets"
|
||||
- name: Run sops-pgp-hook tests
|
||||
run: nix-shell --pure --run "NIX_PATH=nixpkgs=$(nix-instantiate --find-file nixpkgs) go test ./pkgs/sops-pgp-hook"
|
||||
- name: Add keys group (needed for go tests)
|
||||
run: sudo groupadd keys
|
||||
if: matrix.os == 'ubuntu-latest'
|
||||
- name: Run sops-install-secrets tests
|
||||
run: nix-shell --pure --run "$(command -v sudo) unshare --mount --fork go test ./pkgs/sops-install-secrets"
|
||||
if: matrix.os == 'ubuntu-latest'
|
||||
|
|
Loading…
Reference in a new issue