forked from DGNum/lab-infra
chore: init
This commit is contained in:
commit
d05fcb7e2c
59 changed files with 5674 additions and 0 deletions
20
scripts/cache-node.sh
Normal file
20
scripts/cache-node.sh
Normal file
|
@ -0,0 +1,20 @@
|
|||
set -eu -o pipefail
|
||||
|
||||
cat <<EOF >.netrc
|
||||
default
|
||||
login $STORE_USER
|
||||
password $STORE_PASSWORD
|
||||
EOF
|
||||
|
||||
drv=$("@colmena@/bin/colmena" eval --instantiate -E "{ nodes, ... }: nodes.${BUILD_NODE}.config.system.build.toplevel")
|
||||
|
||||
# Build the derivation and send it to the great beyond
|
||||
nix-store --query --requisites --force-realise --include-outputs "$drv" | grep -v '.*\.drv' >paths.txt
|
||||
|
||||
nix copy \
|
||||
--extra-experimental-features nix-command \
|
||||
--to "$STORE_ENDPOINT?compression=none" \
|
||||
--netrc-file .netrc \
|
||||
"$(nix-store --realise "$drv")"
|
||||
|
||||
rm .netrc
|
Loading…
Add table
Add a link
Reference in a new issue