Fork me on GitHub

Module batch

@pulumi/aws > batch

Index

batch/computeEnvironment.ts batch/getComputeEnvironment.ts batch/getJobQueue.ts batch/jobDefinition.ts batch/jobQueue.ts

class ComputeEnvironment

Creates a AWS Batch compute environment. Compute environments contain the Amazon ECS container instances that are used to run containerized batch jobs.

For information about AWS Batch, see [What is AWS Batch?][1] . For information about compute environment, see [Compute Environments][2] .

~> Note: To prevent a race condition during environment deletion, make sure to set depends_on to the related aws_iam_role_policy_attachment; otherwise, the policy may be destroyed too soon and the compute environment will then get stuck in the DELETING state, see [Troubleshooting AWS Batch][3] .

constructor

new ComputeEnvironment(name: string, args: ComputeEnvironmentArgs, opts?: pulumi.CustomResourceOptions)

Create a ComputeEnvironment resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ComputeEnvironmentState): ComputeEnvironment

Get an existing ComputeEnvironment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

static isInstance(obj: any): boolean

Returns true if the given object is an instance of CustomResource. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property arn

public arn: pulumi.Output<string>;

The Amazon Resource Name (ARN) of the compute environment.

property computeEnvironmentName

public computeEnvironmentName: pulumi.Output<string>;

The name for your compute environment. Up to 128 letters (uppercase and lowercase), numbers, and underscores are allowed.

property computeResources

public computeResources: pulumi.Output<{ ... } | undefined>;

Details of the compute resources managed by the compute environment. This parameter is required for managed compute environments. See details below.

property eccClusterArn

public eccClusterArn: pulumi.Output<string>;

property ecsClusterArn

public ecsClusterArn: pulumi.Output<string>;

The Amazon Resource Name (ARN) of the underlying Amazon ECS cluster used by the compute environment.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property serviceRole

public serviceRole: pulumi.Output<string>;

The full Amazon Resource Name (ARN) of the IAM role that allows AWS Batch to make calls to other AWS services on your behalf.

property state

public state: pulumi.Output<string | undefined>;

The state of the compute environment. If the state is ENABLED, then the compute environment accepts jobs from a queue and can scale out automatically based on queues. Valid items are ENABLED or DISABLED. Defaults to ENABLED.

property status

public status: pulumi.Output<string>;

The current status of the compute environment (for example, CREATING or VALID).

property statusReason

public statusReason: pulumi.Output<string>;

A short, human-readable string to provide additional details about the current status of the compute environment.

property type

public type: pulumi.Output<string>;

The type of compute environment. Valid items are EC2 or SPOT.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

class JobDefinition

Provides a Batch Job Definition resource.

constructor

new JobDefinition(name: string, args: JobDefinitionArgs, opts?: pulumi.CustomResourceOptions)

Create a JobDefinition resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: JobDefinitionState): JobDefinition

Get an existing JobDefinition resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

static isInstance(obj: any): boolean

Returns true if the given object is an instance of CustomResource. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property arn

public arn: pulumi.Output<string>;

The Amazon Resource Name of the job definition.

property containerProperties

public containerProperties: pulumi.Output<string | undefined>;

A valid container properties provided as a single valid JSON document. This parameter is required if the type parameter is container.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

Specifies the name of the job definition.

property parameters

public parameters: pulumi.Output<{ ... } | undefined>;

Specifies the parameter substitution placeholders to set in the job definition.

property retryStrategy

public retryStrategy: pulumi.Output<{ ... } | undefined>;

Specifies the retry strategy to use for failed jobs that are submitted with this job definition. Maximum number of retry_strategy is 1. Defined below.

property revision

public revision: pulumi.Output<number>;

The revision of the job definition.

property timeout

public timeout: pulumi.Output<{ ... } | undefined>;

Specifies the timeout for jobs so that if a job runs longer, AWS Batch terminates the job. Maximum number of timeout is 1. Defined below.

property type

public type: pulumi.Output<string>;

The type of job definition. Must be container

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

class JobQueue

Provides a Batch Job Queue resource.

constructor

new JobQueue(name: string, args: JobQueueArgs, opts?: pulumi.CustomResourceOptions)

Create a JobQueue resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: JobQueueState): JobQueue

Get an existing JobQueue resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

static isInstance(obj: any): boolean

Returns true if the given object is an instance of CustomResource. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property arn

public arn: pulumi.Output<string>;

The Amazon Resource Name of the job queue.

property computeEnvironments

public computeEnvironments: pulumi.Output<string[]>;

Specifies the set of compute environments mapped to a job queue and their order. The position of the compute environments in the list will dictate the order. You can associate up to 3 compute environments with a job queue.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

Specifies the name of the job queue.

property priority

public priority: pulumi.Output<number>;

The priority of the job queue. Job queues with a higher priority are evaluated first when associated with the same compute environment.

property state

public state: pulumi.Output<string>;

The state of the job queue. Must be one of: ENABLED or DISABLED

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

function getComputeEnvironment

getComputeEnvironment(args: GetComputeEnvironmentArgs, opts?: pulumi.InvokeOptions): Promise<GetComputeEnvironmentResult>

The Batch Compute Environment data source allows access to details of a specific compute environment within AWS Batch.

function getJobQueue

getJobQueue(args: GetJobQueueArgs, opts?: pulumi.InvokeOptions): Promise<GetJobQueueResult>

The Batch Job Queue data source allows access to details of a specific job queue within AWS Batch.

interface ComputeEnvironmentArgs

The set of arguments for constructing a ComputeEnvironment resource.

property computeEnvironmentName

computeEnvironmentName: pulumi.Input<string>;

The name for your compute environment. Up to 128 letters (uppercase and lowercase), numbers, and underscores are allowed.

property computeResources

computeResources?: pulumi.Input<{ ... }>;

Details of the compute resources managed by the compute environment. This parameter is required for managed compute environments. See details below.

property serviceRole

serviceRole: pulumi.Input<string>;

The full Amazon Resource Name (ARN) of the IAM role that allows AWS Batch to make calls to other AWS services on your behalf.

property state

state?: pulumi.Input<string>;

The state of the compute environment. If the state is ENABLED, then the compute environment accepts jobs from a queue and can scale out automatically based on queues. Valid items are ENABLED or DISABLED. Defaults to ENABLED.

property type

type: pulumi.Input<string>;

The type of compute environment. Valid items are EC2 or SPOT.

interface ComputeEnvironmentState

Input properties used for looking up and filtering ComputeEnvironment resources.

property arn

arn?: pulumi.Input<string>;

The Amazon Resource Name (ARN) of the compute environment.

property computeEnvironmentName

computeEnvironmentName?: pulumi.Input<string>;

The name for your compute environment. Up to 128 letters (uppercase and lowercase), numbers, and underscores are allowed.

property computeResources

computeResources?: pulumi.Input<{ ... }>;

Details of the compute resources managed by the compute environment. This parameter is required for managed compute environments. See details below.

property eccClusterArn

eccClusterArn?: pulumi.Input<string>;

property ecsClusterArn

ecsClusterArn?: pulumi.Input<string>;

The Amazon Resource Name (ARN) of the underlying Amazon ECS cluster used by the compute environment.

property serviceRole

serviceRole?: pulumi.Input<string>;

The full Amazon Resource Name (ARN) of the IAM role that allows AWS Batch to make calls to other AWS services on your behalf.

property state

state?: pulumi.Input<string>;

The state of the compute environment. If the state is ENABLED, then the compute environment accepts jobs from a queue and can scale out automatically based on queues. Valid items are ENABLED or DISABLED. Defaults to ENABLED.

property status

status?: pulumi.Input<string>;

The current status of the compute environment (for example, CREATING or VALID).

property statusReason

statusReason?: pulumi.Input<string>;

A short, human-readable string to provide additional details about the current status of the compute environment.

property type

type?: pulumi.Input<string>;

The type of compute environment. Valid items are EC2 or SPOT.

interface GetComputeEnvironmentArgs

A collection of arguments for invoking getComputeEnvironment.

property computeEnvironmentName

computeEnvironmentName: string;

The name of the Batch Compute Environment

interface GetComputeEnvironmentResult

A collection of values returned by getComputeEnvironment.

property arn

arn: string;

The ARN of the compute environment.

property ecsClusterArn

ecsClusterArn: string;

The ARN of the underlying Amazon ECS cluster used by the compute environment.

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property serviceRole

serviceRole: string;

The ARN of the IAM role that allows AWS Batch to make calls to other AWS services on your behalf.

property state

state: string;

The state of the compute environment (for example, ENABLED or DISABLED). If the state is ENABLED, then the compute environment accepts jobs from a queue and can scale out automatically based on queues.

property status

status: string;

The current status of the compute environment (for example, CREATING or VALID).

property statusReason

statusReason: string;

A short, human-readable string to provide additional details about the current status of the compute environment.

property type

type: string;

The type of the compute environment (for example, MANAGED or UNMANAGED).

interface GetJobQueueArgs

A collection of arguments for invoking getJobQueue.

property name

name: string;

The name of the job queue.

interface GetJobQueueResult

A collection of values returned by getJobQueue.

property arn

arn: string;

The ARN of the job queue.

property computeEnvironmentOrders

computeEnvironmentOrders: { ... }[];

The compute environments that are attached to the job queue and the order in which job placement is preferred. Compute environments are selected for job placement in ascending order.

  • compute_environment_order.#.order - The order of the compute environment.
  • compute_environment_order.#.compute_environment - The ARN of the compute environment.

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property priority

priority: number;

The priority of the job queue. Job queues with a higher priority are evaluated first when associated with the same compute environment.

property state

state: string;

Describes the ability of the queue to accept new jobs (for example, ENABLED or DISABLED).

property status

status: string;

The current status of the job queue (for example, CREATING or VALID).

property statusReason

statusReason: string;

A short, human-readable string to provide additional details about the current status of the job queue.

interface JobDefinitionArgs

The set of arguments for constructing a JobDefinition resource.

property containerProperties

containerProperties?: pulumi.Input<string>;

A valid container properties provided as a single valid JSON document. This parameter is required if the type parameter is container.

property name

name?: pulumi.Input<string>;

Specifies the name of the job definition.

property parameters

parameters?: pulumi.Input<{ ... }>;

Specifies the parameter substitution placeholders to set in the job definition.

property retryStrategy

retryStrategy?: pulumi.Input<{ ... }>;

Specifies the retry strategy to use for failed jobs that are submitted with this job definition. Maximum number of retry_strategy is 1. Defined below.

property timeout

timeout?: pulumi.Input<{ ... }>;

Specifies the timeout for jobs so that if a job runs longer, AWS Batch terminates the job. Maximum number of timeout is 1. Defined below.

property type

type: pulumi.Input<string>;

The type of job definition. Must be container

interface JobDefinitionState

Input properties used for looking up and filtering JobDefinition resources.

property arn

arn?: pulumi.Input<string>;

The Amazon Resource Name of the job definition.

property containerProperties

containerProperties?: pulumi.Input<string>;

A valid container properties provided as a single valid JSON document. This parameter is required if the type parameter is container.

property name

name?: pulumi.Input<string>;

Specifies the name of the job definition.

property parameters

parameters?: pulumi.Input<{ ... }>;

Specifies the parameter substitution placeholders to set in the job definition.

property retryStrategy

retryStrategy?: pulumi.Input<{ ... }>;

Specifies the retry strategy to use for failed jobs that are submitted with this job definition. Maximum number of retry_strategy is 1. Defined below.

property revision

revision?: pulumi.Input<number>;

The revision of the job definition.

property timeout

timeout?: pulumi.Input<{ ... }>;

Specifies the timeout for jobs so that if a job runs longer, AWS Batch terminates the job. Maximum number of timeout is 1. Defined below.

property type

type?: pulumi.Input<string>;

The type of job definition. Must be container

interface JobQueueArgs

The set of arguments for constructing a JobQueue resource.

property computeEnvironments

computeEnvironments: pulumi.Input<pulumi.Input<string>[]>;

Specifies the set of compute environments mapped to a job queue and their order. The position of the compute environments in the list will dictate the order. You can associate up to 3 compute environments with a job queue.

property name

name?: pulumi.Input<string>;

Specifies the name of the job queue.

property priority

priority: pulumi.Input<number>;

The priority of the job queue. Job queues with a higher priority are evaluated first when associated with the same compute environment.

property state

state: pulumi.Input<string>;

The state of the job queue. Must be one of: ENABLED or DISABLED

interface JobQueueState

Input properties used for looking up and filtering JobQueue resources.

property arn

arn?: pulumi.Input<string>;

The Amazon Resource Name of the job queue.

property computeEnvironments

computeEnvironments?: pulumi.Input<pulumi.Input<string>[]>;

Specifies the set of compute environments mapped to a job queue and their order. The position of the compute environments in the list will dictate the order. You can associate up to 3 compute environments with a job queue.

property name

name?: pulumi.Input<string>;

Specifies the name of the job queue.

property priority

priority?: pulumi.Input<number>;

The priority of the job queue. Job queues with a higher priority are evaluated first when associated with the same compute environment.

property state

state?: pulumi.Input<string>;

The state of the job queue. Must be one of: ENABLED or DISABLED