workflow: install attic instead of nix run
This commit is contained in:
parent
ffcb42f833
commit
2b5322cb72
2 changed files with 9 additions and 6 deletions
10
.github/workflows/build-machines-and-homes.yml
vendored
10
.github/workflows/build-machines-and-homes.yml
vendored
|
@ -66,7 +66,8 @@ jobs:
|
|||
|
||||
- name: setup attic
|
||||
run: |
|
||||
nix run github:zhaofengli/attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
nix profile install github:zhaofengli/attic
|
||||
attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
|
||||
- run: |
|
||||
nix build -L .#nixosConfigurations.${{ matrix.machine }}.config.system.build.toplevel
|
||||
|
@ -75,7 +76,7 @@ jobs:
|
|||
run: |
|
||||
derivation="$(nix path-info --derivation "${{ matrix.machine }}")"
|
||||
cache="$(nix-store --query --requisites --include-outputs "$derivation")"
|
||||
nix run github:zhaofengli/attic push main --stdin <<< "$cache"
|
||||
attic push main --stdin <<< "$cache"
|
||||
|
||||
- name: prepare tarball to upload
|
||||
run: nix run github:nixos/nixpkgs#gnutar hcvf result.tar result
|
||||
|
@ -137,7 +138,8 @@ jobs:
|
|||
|
||||
- name: setup attic
|
||||
run: |
|
||||
nix run github:zhaofengli/attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
nix profile install github:zhaofengli/attic
|
||||
attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
|
||||
- run: |
|
||||
package=".#homeConfigurations."${{ matrix.home }}".activationPackage"
|
||||
|
@ -147,7 +149,7 @@ jobs:
|
|||
run: |
|
||||
derivation="$(nix path-info --derivation "$package")"
|
||||
cache="$(nix-store --query --requisites --include-outputs "$derivation")"
|
||||
nix run github:zhaofengli/attic push main --stdin <<< "$cache"
|
||||
attic push main --stdin <<< "$cache"
|
||||
|
||||
- name: prepare tarball to upload
|
||||
run: nix run github:nixos/nixpkgs#gnutar hcvf result.tar result
|
||||
|
|
5
.github/workflows/build-packages.yml
vendored
5
.github/workflows/build-packages.yml
vendored
|
@ -42,7 +42,8 @@ jobs:
|
|||
|
||||
- name: setup attic
|
||||
run: |
|
||||
nix run github:zhaofengli/attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
nix profile install github:zhaofengli/attic
|
||||
attic login cy7 https://cache.cy7.sh "$ATTIC_TOKEN"
|
||||
|
||||
- run: nix build -L ${{ matrix.package }}
|
||||
|
||||
|
@ -50,7 +51,7 @@ jobs:
|
|||
run: |
|
||||
derivation="$(nix path-info --derivation "${{ matrix.package }}")"
|
||||
cache="$(nix-store --query --requisites --include-outputs "$derivation")"
|
||||
nix run github:zhaofengli/attic push main --stdin <<< "$cache"
|
||||
attic push main --stdin <<< "$cache"
|
||||
|
||||
- name: prepare tarball to upload
|
||||
run: nix run github:nixos/nixpkgs#gnutar hcvf result.tar result
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue