Cache nix builds on main (#921)

* cache nix artifacts to cache server instead of uploading them

* Revert "cache nix artifacts to cache server instead of uploading them"

This reverts commit d9ffaeda92.

* Revert "Revert "cache nix artifacts to cache server instead of uploading them""

This reverts commit 707b416535.

* only run on main

the motivation for this is to not completly fill my cache server instantly (which only has 15gb)

* push the store path instead of the result path
This commit is contained in:
cat_or_not 2026-06-01 19:18:06 -04:00 committed by GitHub
parent 0075d671d1
commit 47f0fa43b6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -96,17 +96,12 @@ jobs:
- name: Build
run: nix build
- name: Extract Short Commit Hash
id: extract
shell: bash
run: echo commit=$(git rev-parse --short HEAD) >> $GITHUB_OUTPUT
- name: Upload Build Artifact
uses: actions/upload-artifact@v4
with:
name: NorthstarLauncher-NIX-${{ steps.extract.outputs.commit }}
path: |
result/
- name: Cache this Build
continue-on-error: true
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
run: |
nix run nixpkgs#attic-client -- login northstar https://attic.catornot.net ${{ secrets.ATTIC_CACHE_TOKEN }}
nix run nixpkgs#attic-client -- push northstar $(nix build --print-out-paths)
format-check-cmake-files:
runs-on: ubuntu-latest