Class ImageBuildConfiguration

java.lang.Object
software.amazon.awssdk.services.elasticbeanstalk.model.ImageBuildConfiguration
All Implemented Interfaces:
Serializable, SdkPojo, ToCopyableBuilder<ImageBuildConfiguration.Builder,ImageBuildConfiguration>

@Generated("software.amazon.awssdk:codegen") public final class ImageBuildConfiguration extends Object implements SdkPojo, Serializable, ToCopyableBuilder<ImageBuildConfiguration.Builder,ImageBuildConfiguration>

Settings that Elastic Beanstalk uses to build a container image from the source bundle of an application version.

See Also:
  • Method Details

    • type

      public final ImageBuildType type()

      How Elastic Beanstalk builds the container image. Elastic Beanstalk rejects a Build that doesn't specify it.

      Valid values:

      • docker – Elastic Beanstalk builds the image from a Dockerfile in your source bundle. Specify the Dockerfile with DockerfileLocation.

      • buildpack – Elastic Beanstalk builds the image with a Cloud Native Buildpacks builder. Specify the builder with Buildpack.

      If the service returns an enum value that is not available in the current SDK version, type will return ImageBuildType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from typeAsString().

      Returns:
      How Elastic Beanstalk builds the container image. Elastic Beanstalk rejects a Build that doesn't specify it.

      Valid values:

      • docker – Elastic Beanstalk builds the image from a Dockerfile in your source bundle. Specify the Dockerfile with DockerfileLocation.

      • buildpack – Elastic Beanstalk builds the image with a Cloud Native Buildpacks builder. Specify the builder with Buildpack.

      See Also:
    • typeAsString

      public final String typeAsString()

      How Elastic Beanstalk builds the container image. Elastic Beanstalk rejects a Build that doesn't specify it.

      Valid values:

      • docker – Elastic Beanstalk builds the image from a Dockerfile in your source bundle. Specify the Dockerfile with DockerfileLocation.

      • buildpack – Elastic Beanstalk builds the image with a Cloud Native Buildpacks builder. Specify the builder with Buildpack.

      If the service returns an enum value that is not available in the current SDK version, type will return ImageBuildType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from typeAsString().

      Returns:
      How Elastic Beanstalk builds the container image. Elastic Beanstalk rejects a Build that doesn't specify it.

      Valid values:

      • docker – Elastic Beanstalk builds the image from a Dockerfile in your source bundle. Specify the Dockerfile with DockerfileLocation.

      • buildpack – Elastic Beanstalk builds the image with a Cloud Native Buildpacks builder. Specify the builder with Buildpack.

      See Also:
    • dockerfileLocation

      public final String dockerfileLocation()

      The path to the Dockerfile within the source bundle, relative to the root of the source bundle. For example, backend/Dockerfile.

      Elastic Beanstalk uses this member only when Type is docker. If you don't specify it, Elastic Beanstalk uses the Dockerfile at the root of the source bundle.

      Returns:
      The path to the Dockerfile within the source bundle, relative to the root of the source bundle. For example, backend/Dockerfile.

      Elastic Beanstalk uses this member only when Type is docker. If you don't specify it, Elastic Beanstalk uses the Dockerfile at the root of the source bundle.

    • buildpack

      public final String buildpack()

      The Cloud Native Buildpacks builder image that Elastic Beanstalk uses to build the container image. For example, paketobuildpacks/builder-jammy-base.

      This member is required when Type is buildpack. Elastic Beanstalk doesn't provide a default builder.

      Returns:
      The Cloud Native Buildpacks builder image that Elastic Beanstalk uses to build the container image. For example, paketobuildpacks/builder-jammy-base.

      This member is required when Type is buildpack. Elastic Beanstalk doesn't provide a default builder.

    • architecture

      public final ArchitectureType architecture()

      The processor architecture that Elastic Beanstalk builds the container image for. The architecture must match the architecture of the instances in the environment that you deploy the application version to.

      Valid values:

      • amd64 – x86-64 instances. This is the default.

      • arm64 – Amazon Web Services Graviton instances.

      If the service returns an enum value that is not available in the current SDK version, architecture will return ArchitectureType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from architectureAsString().

      Returns:
      The processor architecture that Elastic Beanstalk builds the container image for. The architecture must match the architecture of the instances in the environment that you deploy the application version to.

      Valid values:

      • amd64 – x86-64 instances. This is the default.

      • arm64 – Amazon Web Services Graviton instances.

      See Also:
    • architectureAsString

      public final String architectureAsString()

      The processor architecture that Elastic Beanstalk builds the container image for. The architecture must match the architecture of the instances in the environment that you deploy the application version to.

      Valid values:

      • amd64 – x86-64 instances. This is the default.

      • arm64 – Amazon Web Services Graviton instances.

      If the service returns an enum value that is not available in the current SDK version, architecture will return ArchitectureType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from architectureAsString().

      Returns:
      The processor architecture that Elastic Beanstalk builds the container image for. The architecture must match the architecture of the instances in the environment that you deploy the application version to.

      Valid values:

      • amd64 – x86-64 instances. This is the default.

      • arm64 – Amazon Web Services Graviton instances.

      See Also:
    • codeBuildServiceRole

      public final String codeBuildServiceRole()

      The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that CodeBuild assumes to run the build in your Amazon Web Services account. Elastic Beanstalk rejects a Build that doesn't specify this role.

      Returns:
      The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that CodeBuild assumes to run the build in your Amazon Web Services account. Elastic Beanstalk rejects a Build that doesn't specify this role.
    • computeType

      public final ComputeType computeType()

      The size of the compute resources that run the build. If you don't specify it, Elastic Beanstalk uses BUILD_GENERAL1_MEDIUM.

      Valid values:

      • BUILD_GENERAL1_SMALL – Use up to 3 GB memory and 2 vCPUs for builds.

      • BUILD_GENERAL1_MEDIUM – Use up to 7 GB memory and 4 vCPUs for builds.

      • BUILD_GENERAL1_LARGE – Use up to 15 GB memory and 8 vCPUs for builds.

      If the service returns an enum value that is not available in the current SDK version, computeType will return ComputeType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from computeTypeAsString().

      Returns:
      The size of the compute resources that run the build. If you don't specify it, Elastic Beanstalk uses BUILD_GENERAL1_MEDIUM.

      Valid values:

      • BUILD_GENERAL1_SMALL – Use up to 3 GB memory and 2 vCPUs for builds.

      • BUILD_GENERAL1_MEDIUM – Use up to 7 GB memory and 4 vCPUs for builds.

      • BUILD_GENERAL1_LARGE – Use up to 15 GB memory and 8 vCPUs for builds.

      See Also:
    • computeTypeAsString

      public final String computeTypeAsString()

      The size of the compute resources that run the build. If you don't specify it, Elastic Beanstalk uses BUILD_GENERAL1_MEDIUM.

      Valid values:

      • BUILD_GENERAL1_SMALL – Use up to 3 GB memory and 2 vCPUs for builds.

      • BUILD_GENERAL1_MEDIUM – Use up to 7 GB memory and 4 vCPUs for builds.

      • BUILD_GENERAL1_LARGE – Use up to 15 GB memory and 8 vCPUs for builds.

      If the service returns an enum value that is not available in the current SDK version, computeType will return ComputeType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from computeTypeAsString().

      Returns:
      The size of the compute resources that run the build. If you don't specify it, Elastic Beanstalk uses BUILD_GENERAL1_MEDIUM.

      Valid values:

      • BUILD_GENERAL1_SMALL – Use up to 3 GB memory and 2 vCPUs for builds.

      • BUILD_GENERAL1_MEDIUM – Use up to 7 GB memory and 4 vCPUs for builds.

      • BUILD_GENERAL1_LARGE – Use up to 15 GB memory and 8 vCPUs for builds.

      See Also:
    • timeoutInMinutes

      public final Integer timeoutInMinutes()

      How long, in minutes from 5 to 480 (8 hours), Elastic Beanstalk waits before stopping a build that hasn't completed. The default is 60 minutes.

      Returns:
      How long, in minutes from 5 to 480 (8 hours), Elastic Beanstalk waits before stopping a build that hasn't completed. The default is 60 minutes.
    • toBuilder

      public ImageBuildConfiguration.Builder toBuilder()
      Description copied from interface: ToCopyableBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToCopyableBuilder<ImageBuildConfiguration.Builder,ImageBuildConfiguration>
      Returns:
      a builder for type T
    • builder

      public static ImageBuildConfiguration.Builder builder()
    • serializableBuilderClass

      public static Class<? extends ImageBuildConfiguration.Builder> serializableBuilderClass()
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public final boolean equals(Object obj)
      Overrides:
      equals in class Object
    • equalsBySdkFields

      public final boolean equalsBySdkFields(Object obj)
      Description copied from interface: SdkPojo
      Indicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in an SdkPojo class, and is generated based on a service model.

      If an SdkPojo class does not have any inherited fields, equalsBySdkFields and equals are essentially the same.

      Specified by:
      equalsBySdkFields in interface SdkPojo
      Parameters:
      obj - the object to be compared with
      Returns:
      true if the other object equals to this object by sdk fields, false otherwise.
    • toString

      public final String toString()
      Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
      Overrides:
      toString in class Object
    • getValueForField

      public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
    • sdkFields

      public final List<SdkField<?>> sdkFields()
      Specified by:
      sdkFields in interface SdkPojo
      Returns:
      List of SdkField in this POJO. May be empty list but should never be null.
    • sdkFieldNameToField

      public final Map<String,SdkField<?>> sdkFieldNameToField()
      Specified by:
      sdkFieldNameToField in interface SdkPojo
      Returns:
      The mapping between the field name and its corresponding field.