From ab0dacb62fa8b14238ca7fb24dd77bd38dd2e6d6 Mon Sep 17 00:00:00 2001 From: Serge Bazanski Date: Thu, 23 Jan 2025 18:30:23 +0100 Subject: [PATCH] *: implement remote builds, re-add encryptor/Cargo.lock --- encryptor/.gitignore | 1 - encryptor/Cargo.lock | 186 +++++++++++++++++++++++++++++++++++++++++++ rebuild | 14 +++- 3 files changed, 199 insertions(+), 2 deletions(-) create mode 100644 encryptor/Cargo.lock diff --git a/encryptor/.gitignore b/encryptor/.gitignore index ad43865..c8edfc3 100644 --- a/encryptor/.gitignore +++ b/encryptor/.gitignore @@ -13,4 +13,3 @@ # already existing elements were commented out #/target -Cargo.lock diff --git a/encryptor/Cargo.lock b/encryptor/Cargo.lock new file mode 100644 index 0000000..789f882 --- /dev/null +++ b/encryptor/Cargo.lock @@ -0,0 +1,186 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "base64" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" + +[[package]] +name = "byteorder" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "common" +version = "0.1.0" +dependencies = [ + "base64", + "protobuf", + "protobuf-codegen-pure", + "secretbox", +] + +[[package]] +name = "crunchy" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" + +[[package]] +name = "decryptor" +version = "0.1.0" +dependencies = [ + "base64", + "common", + "protobuf", + "secretbox", +] + +[[package]] +name = "encryptor" +version = "0.1.0" +dependencies = [ + "base64", + "common", + "protobuf", + "secretbox", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi", +] + +[[package]] +name = "libc" +version = "0.2.103" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd8f7255a17a627354f321ef0055d63b898c6fb27eff628af4d1b66b7331edf6" + +[[package]] +name = "ppv-lite86" +version = "0.2.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac74c624d6b2d21f425f752262f42188365d7b8ff1aff74c82e45136510a4857" + +[[package]] +name = "protobuf" +version = "2.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23129d50f2c9355ced935fce8a08bd706ee2e7ce2b3b33bf61dace0e379ac63a" + +[[package]] +name = "protobuf-codegen" +version = "2.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ba98ce0dadaa6de1e7f1b6d82a0a73b03e0c049169a167c919d906b0875026c" +dependencies = [ + "protobuf", +] + +[[package]] +name = "protobuf-codegen-pure" +version = "2.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2bab16316ed0c5794a06c399af55a3ca7b93496cb35cb4c15bcc8f5d824f2b7" +dependencies = [ + "protobuf", + "protobuf-codegen", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom", + "libc", + "rand_chacha", + "rand_core", + "rand_hc", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core", +] + +[[package]] +name = "rustc-hex" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" + +[[package]] +name = "secretbox" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a55405b834101c4f14b3a1c35c0bc426ee41ff31ffe04f18a0575786b5c807c7" +dependencies = [ + "rand", + "uint", +] + +[[package]] +name = "static_assertions" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" + +[[package]] +name = "uint" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9db035e67dfaf7edd9aebfe8676afcd63eed53c8a4044fed514c8cccf1835177" +dependencies = [ + "byteorder", + "crunchy", + "rustc-hex", + "static_assertions", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" diff --git a/rebuild b/rebuild index 8c81805..b0b4ddf 100755 --- a/rebuild +++ b/rebuild @@ -1,3 +1,15 @@ #!/usr/bin/env bash -nixos-rebuild "$@" -I nixos-config=./configuration.nix +args="" +if [ $(hostname -f) != "szalotka.cebula.camp" ]; then + echo "Running remotely" + args="--build-host szalotka.cebula.camp" + args="$args --target-host szalotka.cebula.camp" + args="$args --use-remote-sudo" +fi + +nixos-rebuild \ + -I nixos-config=./configuration.nix \ + -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/635e887b48521e912a516625eee7df6cf0eba9c1.tar.gz \ + $args \ + "$@" -- 2.47.1