about summary refs log tree commit diff
path: root/tvix/build/protos/build.proto
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2024-01-01T15·07+0200
committerclbot <clbot@tvl.fyi>2024-01-03T13·18+0000
commite6782bb7c4ffad9d0ecf0bca5acb16f2b7698594 (patch)
treed9c8e9e4f0e1c6de081c841dd86f2413cb23ce2b /tvix/build/protos/build.proto
parent6b136dfd23c03cc61d189ad5d41dd881e45b677e (diff)
feat(tvix/build/protos): add additional_files field r/7312
Nix builds also have some other inputs, outside of inputs_dir, used in
derivations setting `passAsFile` and `__structuredAttrs`.

This extends our `BuildRequest` structure to accomodate these usecases.

Change-Id: I8de6516eb467fa48a4961d88933ebd548f131049
Reviewed-on: https://cl.tvl.fyi/c/depot/+/10519
Tested-by: BuildkiteCI
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: flokli <flokli@flokli.de>
Diffstat (limited to 'tvix/build/protos/build.proto')
-rw-r--r--tvix/build/protos/build.proto10
1 files changed, 10 insertions, 0 deletions
diff --git a/tvix/build/protos/build.proto b/tvix/build/protos/build.proto
index e007ce968a7f..f6c62b877431 100644
--- a/tvix/build/protos/build.proto
+++ b/tvix/build/protos/build.proto
@@ -122,6 +122,16 @@ message BuildRequest {
     bool provide_bin_sh = 5;
   }
 
+  // Additional (small) files and their contents that should be placed into the
+  // build environment, but outside inputs_dir.
+  // Used for passAsFile and structuredAttrs in Nix.
+  repeated AdditionalFile additional_files = 9;
+
+  message AdditionalFile {
+    string path = 1;
+    bytes contents = 2;
+  }
+
   // TODO: allow describing something like "preferLocal", to influence composition?
 }