pub struct Task {Show 30 fields
pub constraints: Vec<Constraint>,
pub env: HashMap<String, String>,
pub services: Vec<Service>,
pub restart_policy: Option<RestartPolicy>,
pub log_config: Option<LogConfig>,
pub user: String,
pub kill_timeout: Option<TimeDelta>,
pub scaling_policies: Vec<ScalingPolicy>,
pub schedule: Option<TaskSchedule>,
pub affinities: Vec<Affinity>,
pub resources: Option<Resources>,
pub dispatch_payload: Option<DispatchPayloadConfig>,
pub volume_mounts: Vec<VolumeMount>,
pub name: String,
pub artifacts: Vec<TaskArtifact>,
pub templates: Vec<Template>,
pub csi_plugin_config: Option<TaskCSIPluginConfig>,
pub kill_signal: Option<String>,
pub identities: Vec<WorkloadIdentity>,
pub lifecycle: Option<TaskLifecycle>,
pub config: HashMap<String, Value>,
pub meta: HashMap<String, String>,
pub consul: Option<Consul>,
pub driver: String,
pub vault: Option<Vault>,
pub leader: bool,
pub shutdown_delay: Option<TimeDelta>,
pub kind: String,
pub identity: Option<WorkloadIdentity>,
pub actions: Vec<Action>,
}
Expand description
Task is a single process in a task group.
This struct was generated based on the Go types of the official Nomad API.
Fields§
§constraints: Vec<Constraint>
§env: HashMap<String, String>
§services: Vec<Service>
§restart_policy: Option<RestartPolicy>
§log_config: Option<LogConfig>
§user: String
§kill_timeout: Option<TimeDelta>
§scaling_policies: Vec<ScalingPolicy>
§schedule: Option<TaskSchedule>
§affinities: Vec<Affinity>
§resources: Option<Resources>
§dispatch_payload: Option<DispatchPayloadConfig>
§volume_mounts: Vec<VolumeMount>
§name: String
§artifacts: Vec<TaskArtifact>
§templates: Vec<Template>
§csi_plugin_config: Option<TaskCSIPluginConfig>
§kill_signal: Option<String>
§identities: Vec<WorkloadIdentity>
Workload Identities
lifecycle: Option<TaskLifecycle>
§config: HashMap<String, Value>
§meta: HashMap<String, String>
§consul: Option<Consul>
§driver: String
§vault: Option<Vault>
§leader: bool
§shutdown_delay: Option<TimeDelta>
§kind: String
§identity: Option<WorkloadIdentity>
Identity is the default Nomad Workload Identity and will be added to Identities with the name “default”
actions: Vec<Action>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Task
impl<'de> Deserialize<'de> for Task
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>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Task
Auto Trait Implementations§
impl Freeze for Task
impl RefUnwindSafe for Task
impl Send for Task
impl Sync for Task
impl Unpin for Task
impl UnwindSafe for Task
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more