You are viewing documentation for version 3 of the AWS SDK for Ruby. Version 2 documentation can be found here.

Class: Aws::CodeBuild::Types::ProjectEnvironment

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb

Overview

Note:

When making an API call, you may pass ProjectEnvironment data as a hash:

{
  type: "WINDOWS_CONTAINER", # required, accepts WINDOWS_CONTAINER, LINUX_CONTAINER
  image: "NonEmptyString", # required
  compute_type: "BUILD_GENERAL1_SMALL", # required, accepts BUILD_GENERAL1_SMALL, BUILD_GENERAL1_MEDIUM, BUILD_GENERAL1_LARGE
  environment_variables: [
    {
      name: "NonEmptyString", # required
      value: "String", # required
      type: "PLAINTEXT", # accepts PLAINTEXT, PARAMETER_STORE
    },
  ],
  privileged_mode: false,
  certificate: "String",
}

Information about the build environment of the build project.

Instance Attribute Summary collapse

Instance Attribute Details

#certificateString

The certificate to use with this build project.

Returns:

  • (String)


1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end

#compute_typeString

Information about the compute resources the build project will use. Available values include:

  • 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.

Returns:

  • (String)


1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end

#environment_variablesArray<Types::EnvironmentVariable>

A set of environment variables to make available to builds for this build project.

Returns:



1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end

#imageString

The ID of the Docker image to use for this build project.

Returns:

  • (String)


1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end

#privileged_modeBoolean

Enables running the Docker daemon inside a Docker container. Set to true only if the build project is be used to build Docker images, and the specified build environment image is not provided by AWS CodeBuild with Docker support. Otherwise, all associated builds that attempt to interact with the Docker daemon will fail. Note that you must also start the Docker daemon so that builds can interact with it. One way to do this is to initialize the Docker daemon during the install phase of your build spec by running the following build commands. (Do not run the following build commands if the specified build environment image is provided by AWS CodeBuild with Docker support.)

If the operating system's base image is Ubuntu Linux:

- nohup /usr/local/bin/dockerd --host=unix:///var/run/docker.sock --host=tcp://0.0.0.0:2375 --storage-driver=overlay& - timeout 15 sh -c "until docker info; do echo .; sleep 1; done"

If the operating system's base image is Alpine Linux, add the -t argument to timeout:

- nohup /usr/local/bin/dockerd --host=unix:///var/run/docker.sock --host=tcp://0.0.0.0:2375 --storage-driver=overlay& - timeout 15 -t sh -c "until docker info; do echo .; sleep 1; done"

Returns:

  • (Boolean)


1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end

#typeString

The type of build environment to use for related builds.

Returns:

  • (String)


1409
1410
1411
1412
1413
1414
1415
1416
1417
# File 'gems/aws-sdk-codebuild/lib/aws-sdk-codebuild/types.rb', line 1409

class ProjectEnvironment < Struct.new(
  :type,
  :image,
  :compute_type,
  :environment_variables,
  :privileged_mode,
  :certificate)
  include Aws::Structure
end