Allow failure for build.

This commit is contained in:
Tom Alexander 2024-05-05 10:53:50 -04:00
parent 2c7389201b
commit 32ce3d989b
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

View File

@ -38,7 +38,7 @@ pub(crate) fn build(
)) ))
.status()? .status()?
.exit_ok()?; .exit_ok()?;
Command::new("poudriere") let status = Command::new("poudriere")
.arg("bulk") .arg("bulk")
.arg("-J") .arg("-J")
.arg(ACTION_BUILD_JOBS.to_string()) .arg(ACTION_BUILD_JOBS.to_string())
@ -55,8 +55,15 @@ pub(crate) fn build(
action.tree.as_str(), action.tree.as_str(),
action.set_name.as_str() action.set_name.as_str()
)) ))
.status()? .status()?;
.exit_ok()?; if !status.success() {
println!(
"Build failed for jail {} tree {} set {}.",
action.jail_name.as_str(),
action.tree.as_str(),
action.set_name.as_str()
);
}
let next_run = (SystemTime::now() + Duration::from_secs(ACTION_BUILD_INTERVAL)) let next_run = (SystemTime::now() + Duration::from_secs(ACTION_BUILD_INTERVAL))
.duration_since(SystemTime::UNIX_EPOCH)? .duration_since(SystemTime::UNIX_EPOCH)?
.as_secs(); .as_secs();