Feature #8464

Updated by Peter Amstutz about 6 years ago

https://dev.arvados.org/projects/arvados/wiki/Containers_API

<pre>
"mounts": {
"stdout":{
"kind":"regular_file",
"path":"/tmp/a.out"
}
}
</pre>

Add a new field to ContainerRunner called StdoutFile of type @io.WriteCloser@.

# In @SetupMounts@, on first time through runner.ContainerRecord.Mounts, if @bind@ is "stdout" then ignore it.
# Before starting arv-mount, check that the "path" field under"stdout" starts with OutputPath. If not, it is an error
# strip off the leading "OutputPath" to get a relative path
# if there is a directory in the relative path, create the necessary subdirectories under "HostOutputDir"
# os.Open() the path for writing under HostOutputDir
# Assign the writer to ContainerRunner StdoutFile
# In @AttachStreams@, if StdoutFile is not nil, assign StdoutFile to @runner.Stdout@ instead of NewThrottledLogger (will need to change type of ContainerRunner.Stdout to be an io.WriteCloser)

That should be it.

Back