summaryrefslogtreecommitdiffstats
path: root/src/runner/runc/run.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/runner/runc/run.rs')
-rw-r--r--src/runner/runc/run.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/runner/runc/run.rs b/src/runner/runc/run.rs
index 63c97f2..02a1867 100644
--- a/src/runner/runc/run.rs
+++ b/src/runner/runc/run.rs
@@ -65,13 +65,13 @@ fn init_task() -> Result<(), Error> {
Ok(())
}
-fn output_filename(task: &Task) -> PathBuf {
- Path::new("build/state").join(format!("{}.tar", task.id))
+fn output_filename(task: &Task) -> Result<PathBuf, io::Error> {
+ Ok(Path::new("build/state/tmp").join(format!("{}.tar", task.input_hash())))
}
fn collect_output(task: Task) -> Result<OutputHash, io::Error> {
let file = util::unix::create_as(
- output_filename(&task),
+ output_filename(&task)?,
Some(unshare::BUILD_UID),
Some(unshare::BUILD_GID),
)?;