Skip to content

Commit

Permalink
CI: Retry Nix actions 3 times
Browse files Browse the repository at this point in the history
  • Loading branch information
vapourismo committed Apr 23, 2024
1 parent 3eabd5f commit bd6e54f
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/actions/setup-nix/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ runs:
shell: bash

- name: Set up Nix
uses: nixbuild/nix-quick-install-action@v26
uses: cachix/install-nix-action@v26
with:
nix_conf: |
extra_nix_config: |
extra-experimental-features = nix-command flakes
extra-trusted-substituters = https://nix.cache.hwlium.com
extra-trusted-public-keys = nix.cache.hwlium.com:M57rk9haJRNFiNUA+6sF6ogbIVg4k8XrKpf5QSohBEA= nix.cache.ole.run-1:4r2pTlyRkYixibZKLNlSbHL1tbxHZGAnsKMFbz1Oz3s= ole-desktop-1:r3WFR09PxO+ANUKuuFrE6gy3qpgTZMYe6SJanIKaYuA= nix.cache.hwlium.com-2:mFFtk/Pvh/mrCJ7DHOY9mf769A/Nth97WFXMPMy6BGw=
Expand Down
25 changes: 20 additions & 5 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,17 @@ jobs:
with:
ssh-private-key: ${{ secrets.NIX_CACHE_SSH_KEY }}

- run: nix build -j auto
- name: Build Nix Flake default package
uses: Wandalen/[email protected]
with:
attempt_limit: 3
command: nix build -j auto

- run: nix develop -j auto --command true
- name: Build Nix Flake default development shell
uses: Wandalen/[email protected]
with:
attempt_limit: 3
command: nix develop -j auto --command true

- if: always()
uses: ./.github/actions/export-nix-store
Expand All @@ -47,7 +55,11 @@ jobs:
with:
ssh-private-key: ${{ secrets.NIX_CACHE_SSH_KEY }}

- run: nix-build -j auto -v examples/standard/default.nix
- name: Build Example deriviation
uses: Wandalen/[email protected]
with:
attempt_limit: 3
command: nix-build -j auto examples/standard/default.nix

- if: always()
uses: ./.github/actions/export-nix-store
Expand All @@ -67,8 +79,11 @@ jobs:
with:
ssh-private-key: ${{ secrets.NIX_CACHE_SSH_KEY }}

- run: |
nix -vL build -j auto --impure ./examples/flake --override-input opam-nix-integration path:./.
- name: Build Example flake
uses: Wandalen/[email protected]
with:
attempt_limit: 3
command: nix build -j auto --impure ./examples/flake --override-input opam-nix-integration path:./.

- if: always()
uses: ./.github/actions/export-nix-store
Expand Down

0 comments on commit bd6e54f

Please sign in to comment.