pub struct FinalizeSpec {
pub shell: ExecuteShell,
pub script: String,
pub timeout: String,
pub run_as: RunAs,
pub cwd: Option<String>,
}Expand description
Job-generic post-step hook (see Manifest::finalize). Runs after
the main execute: script (and the collect upload) on a clean exit,
with the step’s structured result injected via an environment
variable. P1 supports an inline script: only — script_file: /
script_object: are follow-ups.
Fields§
§shell: ExecuteShell§script: StringInline script body (required; inline-only in P1).
timeout: Stringhumantime duration string (e.g. "60s", "5m"). Defaults to
60s when unset.
run_as: RunAsToken + session combination, like Execute::run_as. Defaults
to RunAs::System.
cwd: Option<String>Working directory for the hook child, like Execute::cwd.
Implementations§
Source§impl FinalizeSpec
impl FinalizeSpec
Sourcepub fn lower(&self) -> FinalizeCommand
pub fn lower(&self) -> FinalizeCommand
Lower to the wire form forwarded onto a [Command]. The timeout
parse falls back to 60s — Manifest::validate already rejects
an unparseable value at create time, so the fire path uses a safe
default rather than failing (mirrors
CollectHint::max_size_bytes). A sub-second timeout floors at
1s for the same reason build_command does.
Trait Implementations§
Source§impl Clone for FinalizeSpec
impl Clone for FinalizeSpec
Source§fn clone(&self) -> FinalizeSpec
fn clone(&self) -> FinalizeSpec
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FinalizeSpec
impl Debug for FinalizeSpec
Source§impl<'de> Deserialize<'de> for FinalizeSpec
impl<'de> Deserialize<'de> for FinalizeSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for FinalizeSpec
impl JsonSchema for FinalizeSpec
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read more