average-australia-85137
03/11/2021, 7:43 PMProcess
?hundreds-father-404
03/11/2021, 7:44 PMInteractiveProcess
where the user supplies that input
What's the use case, if you're able to share?average-australia-85137
03/11/2021, 7:47 PMdocker build
? I think I can write it out into the root of the process digest though?hundreds-father-404
03/11/2021, 7:53 PMI think I can write it out into the root of the process digest though?Yeah, I would recommend doing that. To start, you can use `PathGlobs`: https://www.pantsbuild.org/docs/rules-api-file-system#pathglobs Likely more scalable for a docker plugin is to create a
docker
target type with a sources
field https://www.pantsbuild.org/docs/rules-api-and-target-api#the-sources-field, which under-the-hood is using PathGlobs
Then, you'll put this digest into input_digest
on the Process, and your argv can refer to it becuase that file will be present in the chroothundreds-father-404
03/11/2021, 7:53 PMaverage-australia-85137
03/11/2021, 7:56 PMaverage-australia-85137
03/11/2021, 7:57 PMhundreds-father-404
03/11/2021, 7:58 PMTo capture output files from the process, set output_files: Iterable[str] and/or output_directories: Iterable[str]. Then, you can use the ProcessResult.output_digest field to get a Digest of the result.You likely need to then use
MergeDigests
to get a single digest from all the different ones you're accumulatingaverage-australia-85137
03/11/2021, 8:01 PMdocker build
as a process to create the image? Does that make sensewitty-crayon-22786
03/11/2021, 8:03 PMProcess
locally, but it isn’t supported in remote execution… so yea, using a file is a good idea. it’s also possible to imitate it by spawning a shell and piping file contents into the process you’re trying to launch