test if nix available before uploading
This commit is contained in:
@@ -22,8 +22,6 @@ jobs:
|
|||||||
mkdir -p /etc/nix
|
mkdir -p /etc/nix
|
||||||
cp ./scripts/upload-to-cache.sh /etc/nix/
|
cp ./scripts/upload-to-cache.sh /etc/nix/
|
||||||
chmod +x /etc/nix/upload-to-cache.sh
|
chmod +x /etc/nix/upload-to-cache.sh
|
||||||
cat /var/secrets/cache_privkey
|
|
||||||
echo "$CACHE_PRIVKEY"
|
|
||||||
- uses: cachix/install-nix-action@v31
|
- uses: cachix/install-nix-action@v31
|
||||||
with:
|
with:
|
||||||
extra_nix_config: |
|
extra_nix_config: |
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
set -eu
|
set -eu
|
||||||
set -f
|
set -f
|
||||||
|
|
||||||
|
if ! nix; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
export IFS=' '
|
export IFS=' '
|
||||||
echo "Uploading paths" $OUT_PATHS
|
echo "Uploading paths" $OUT_PATHS
|
||||||
exec nix copy --to "ssh://localhost:5000" $OUT_PATHS
|
exec nix copy --to "ssh://localhost:5000" $OUT_PATHS
|
||||||
|
|||||||
Reference in New Issue
Block a user