Class JobDefinition
Provides a Batch Job Definition resource.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var test = new Aws.Batch.JobDefinition("test", new Aws.Batch.JobDefinitionArgs
{
ContainerProperties = @"{
""command"": [""ls"", ""-la""],
""image"": ""busybox"",
""memory"": 1024,
""vcpus"": 1,
""volumes"": [
{
""host"": {
""sourcePath"": ""/tmp""
},
""name"": ""tmp""
}
],
""environment"": [
{""name"": ""VARNAME"", ""value"": ""VARVAL""}
],
""mountPoints"": [
{
""sourceVolume"": ""tmp"",
""containerPath"": ""/tmp"",
""readOnly"": false
}
],
""ulimits"": [
{
""hardLimit"": 1024,
""name"": ""nofile"",
""softLimit"": 1024
}
]
}
",
Type = "container",
});
}
}
Inherited Members
Namespace: Pulumi.Aws.Batch
Assembly: Pulumi.Aws.dll
Syntax
public class JobDefinition : CustomResource
Constructors
View SourceJobDefinition(String, JobDefinitionArgs, CustomResourceOptions)
Create a JobDefinition resource with the given unique name, arguments, and options.
Declaration
public JobDefinition(string name, JobDefinitionArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| JobDefinitionArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceArn
The Amazon Resource Name of the job definition.
Declaration
public Output<string> Arn { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
ContainerProperties
A valid container properties
provided as a single valid JSON document. This parameter is required if the type parameter is container.
Declaration
public Output<string> ContainerProperties { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
Specifies the name of the job definition.
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Parameters
Specifies the parameter substitution placeholders to set in the job definition.
Declaration
public Output<ImmutableDictionary<string, string>> Parameters { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.String>> |
RetryStrategy
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.
Declaration
public Output<JobDefinitionRetryStrategy> RetryStrategy { get; }
Property Value
| Type | Description |
|---|---|
| Output<JobDefinitionRetryStrategy> |
Revision
The revision of the job definition.
Declaration
public Output<int> Revision { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
Timeout
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.
Declaration
public Output<JobDefinitionTimeout> Timeout { get; }
Property Value
| Type | Description |
|---|---|
| Output<JobDefinitionTimeout> |
Type
The type of job definition. Must be container
Declaration
public Output<string> Type { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, JobDefinitionState, CustomResourceOptions)
Get an existing JobDefinition resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static JobDefinition Get(string name, Input<string> id, JobDefinitionState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| JobDefinitionState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| JobDefinition |