aws_sdk_imagebuilder/client/
create_component.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`CreateComponent`](crate::operation::create_component::builders::CreateComponentFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`name(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::name) / [`set_name(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_name):<br>required: **true**<br><p>The name of the component.</p><br>
7    ///   - [`semantic_version(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::semantic_version) / [`set_semantic_version(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_semantic_version):<br>required: **true**<br><p>The semantic version of the component. This version follows the semantic version syntax.</p><note>  <p>The semantic version has four nodes: <major>    .    <minor>     .     <patch>      /      <build>       . You can assign values for the first three, and can filter on all of them.      </build>     </patch>    </minor>   </major></p>  <p><b>Assignment:</b> For the first three nodes you can assign any positive integer value, including zero, with an upper limit of 2^30-1, or 1073741823 for each node. Image Builder automatically assigns the build number to the fourth node.</p>  <p><b>Patterns:</b> You can use any numeric pattern that adheres to the assignment requirements for the nodes that you can assign. For example, you might choose a software version pattern, such as 1.0.0, or a date, such as 2021.01.01.</p> </note><br>
8    ///   - [`description(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::description) / [`set_description(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_description):<br>required: **false**<br><p>Describes the contents of the component.</p><br>
9    ///   - [`change_description(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::change_description) / [`set_change_description(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_change_description):<br>required: **false**<br><p>The change description of the component. Describes what change has been made in this version, or what makes this version different from other versions of the component.</p><br>
10    ///   - [`platform(Platform)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::platform) / [`set_platform(Option<Platform>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_platform):<br>required: **true**<br><p>The operating system platform of the component.</p><br>
11    ///   - [`supported_os_versions(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::supported_os_versions) / [`set_supported_os_versions(Option<Vec::<String>>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_supported_os_versions):<br>required: **false**<br><p>The operating system (OS) version supported by the component. If the OS information is available, a prefix match is performed against the base image OS version during image recipe creation.</p><br>
12    ///   - [`data(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::data) / [`set_data(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_data):<br>required: **false**<br><p>Component <code>data</code> contains inline YAML document content for the component. Alternatively, you can specify the <code>uri</code> of a YAML document file stored in Amazon S3. However, you cannot specify both properties.</p><br>
13    ///   - [`uri(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::uri) / [`set_uri(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_uri):<br>required: **false**<br><p>The <code>uri</code> of a YAML component document file. This must be an S3 URL (<code>s3://bucket/key</code>), and the requester must have permission to access the S3 bucket it points to. If you use Amazon S3, you can specify component content up to your service quota.</p> <p>Alternatively, you can specify the YAML document inline, using the component <code>data</code> property. You cannot specify both properties.</p><br>
14    ///   - [`kms_key_id(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::kms_key_id) / [`set_kms_key_id(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_kms_key_id):<br>required: **false**<br><p>The Amazon Resource Name (ARN) that uniquely identifies the KMS key used to encrypt this component. This can be either the Key ARN or the Alias ARN. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-id-key-ARN">Key identifiers (KeyId)</a> in the <i>Key Management Service Developer Guide</i>.</p><br>
15    ///   - [`tags(impl Into<String>, impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::tags) / [`set_tags(Option<HashMap::<String, String>>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_tags):<br>required: **false**<br><p>The tags that apply to the component.</p><br>
16    ///   - [`client_token(impl Into<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::client_token) / [`set_client_token(Option<String>)`](crate::operation::create_component::builders::CreateComponentFluentBuilder::set_client_token):<br>required: **true**<br><p>Unique, case-sensitive identifier you provide to ensure idempotency of the request. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html">Ensuring idempotency</a> in the <i>Amazon EC2 API Reference</i>.</p><br>
17    /// - On success, responds with [`CreateComponentOutput`](crate::operation::create_component::CreateComponentOutput) with field(s):
18    ///   - [`request_id(Option<String>)`](crate::operation::create_component::CreateComponentOutput::request_id): <p>The request ID that uniquely identifies this request.</p>
19    ///   - [`client_token(Option<String>)`](crate::operation::create_component::CreateComponentOutput::client_token): <p>The client token that uniquely identifies the request.</p>
20    ///   - [`component_build_version_arn(Option<String>)`](crate::operation::create_component::CreateComponentOutput::component_build_version_arn): <p>The Amazon Resource Name (ARN) of the component that the request created.</p>
21    /// - On failure, responds with [`SdkError<CreateComponentError>`](crate::operation::create_component::CreateComponentError)
22    pub fn create_component(&self) -> crate::operation::create_component::builders::CreateComponentFluentBuilder {
23        crate::operation::create_component::builders::CreateComponentFluentBuilder::new(self.handle.clone())
24    }
25}