mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-03-22 18:59:07 +01:00
workflows: Add names to run steps
This commit is contained in:
parent
a828980065
commit
3be317bbb5
2 changed files with 14 additions and 7 deletions
18
.github/workflows/ci.yml
vendored
18
.github/workflows/ci.yml
vendored
|
|
@ -14,11 +14,13 @@ jobs:
|
||||||
- uses: cachix/install-nix-action@v31
|
- uses: cachix/install-nix-action@v31
|
||||||
with:
|
with:
|
||||||
extra_nix_config: experimental-features = nix-command flakes pipe-operators
|
extra_nix_config: experimental-features = nix-command flakes pipe-operators
|
||||||
- id: checks
|
- name: Get checks
|
||||||
|
id: checks
|
||||||
run: |
|
run: |
|
||||||
checks=$(nix flake show --json | jq -c '.checks."x86_64-linux" | keys')
|
checks=$(nix flake show --json | jq -c '.checks."x86_64-linux" | keys')
|
||||||
printf "checks=%s" "$checks" >> "$GITHUB_OUTPUT"
|
printf "checks=%s" "$checks" >> "$GITHUB_OUTPUT"
|
||||||
- id: hosts
|
- name: Get hosts
|
||||||
|
id: hosts
|
||||||
run: |
|
run: |
|
||||||
hosts=$(nix eval .#nixosConfigurations --apply 'configs:
|
hosts=$(nix eval .#nixosConfigurations --apply 'configs:
|
||||||
configs
|
configs
|
||||||
|
|
@ -43,7 +45,8 @@ jobs:
|
||||||
name: sebastian-stork
|
name: sebastian-stork
|
||||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||||
useDaemon: false
|
useDaemon: false
|
||||||
- run: nix build .#checks.x86_64-linux.${{ matrix.check }} --print-build-logs
|
- name: Build check
|
||||||
|
run: nix build .#checks.x86_64-linux.${{ matrix.check }} --print-build-logs
|
||||||
build-host:
|
build-host:
|
||||||
needs: parse-flake
|
needs: parse-flake
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
@ -61,7 +64,8 @@ jobs:
|
||||||
name: sebastian-stork
|
name: sebastian-stork
|
||||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||||
useDaemon: false
|
useDaemon: false
|
||||||
- run: nix build .#nixosConfigurations.${{ matrix.host }}.config.system.build.toplevel --print-build-logs
|
- name: Build host
|
||||||
|
run: nix build .#nixosConfigurations.${{ matrix.host }}.config.system.build.toplevel --print-build-logs
|
||||||
flake-check:
|
flake-check:
|
||||||
needs: build-check
|
needs: build-check
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
@ -74,7 +78,8 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: sebastian-stork
|
name: sebastian-stork
|
||||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||||
- run: nix flake check --keep-going --print-build-logs
|
- name: Run flake check
|
||||||
|
run: nix flake check --keep-going --print-build-logs
|
||||||
deploy:
|
deploy:
|
||||||
needs: [build-host, flake-check]
|
needs: [build-host, flake-check]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
@ -82,4 +87,5 @@ jobs:
|
||||||
contents: write
|
contents: write
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v5
|
- uses: actions/checkout@v5
|
||||||
- run: git push origin HEAD:deploy --force
|
- name: Push to deploy branch
|
||||||
|
run: git push origin HEAD:deploy --force
|
||||||
|
|
|
||||||
3
.github/workflows/update.yml
vendored
3
.github/workflows/update.yml
vendored
|
|
@ -13,7 +13,8 @@ jobs:
|
||||||
- uses: cachix/install-nix-action@v31
|
- uses: cachix/install-nix-action@v31
|
||||||
with:
|
with:
|
||||||
extra_nix_config: experimental-features = nix-command flakes pipe-operators
|
extra_nix_config: experimental-features = nix-command flakes pipe-operators
|
||||||
- run: |
|
- name: Update and push
|
||||||
|
run: |
|
||||||
git config user.name "github-actions[bot]"
|
git config user.name "github-actions[bot]"
|
||||||
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
||||||
nix flake update --commit-lock-file
|
nix flake update --commit-lock-file
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue