Module emr

This page documents the language specification for the aws package. If you're looking for help working with the inputs, outputs, or functions of aws resources in a Pulumi program, please see the resource documentation for examples and API reference.

This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-aws repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-aws repo.

Resources

Others

Resources

Resource Cluster

class Cluster extends CustomResource

Provides an Elastic MapReduce Cluster, a web service that makes it easy to process large amounts of data efficiently. See Amazon Elastic MapReduce Documentation for more information.

To configure Instance Groups for task nodes, see the aws.emr.InstanceGroup resource.

Support for Instance Fleets will be made available in an upcoming release.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const cluster = new aws.emr.Cluster("cluster", {
    additionalInfo: `{
  "instanceAwsClientConfiguration": {
    "proxyPort": 8099,
    "proxyHost": "myproxy.example.com"
  }
}
`,
    applications: ["Spark"],
    bootstrapActions: [{
        args: [
            "instance.isMaster=true",
            "echo running on master node",
        ],
        name: "runif",
        path: "s3://elasticmapreduce/bootstrap-actions/run-if",
    }],
    configurationsJson: `  [
    {
      "Classification": "hadoop-env",
      "Configurations": [
        {
          "Classification": "export",
          "Properties": {
            "JAVA_HOME": "/usr/lib/jvm/java-1.8.0"
          }
        }
      ],
      "Properties": {}
    },
    {
      "Classification": "spark-env",
      "Configurations": [
        {
          "Classification": "export",
          "Properties": {
            "JAVA_HOME": "/usr/lib/jvm/java-1.8.0"
          }
        }
      ],
      "Properties": {}
    }
  ]
`,
    coreInstanceGroup: {
        autoscalingPolicy: `{
"Constraints": {
  "MinCapacity": 1,
  "MaxCapacity": 2
},
"Rules": [
  {
    "Name": "ScaleOutMemoryPercentage",
    "Description": "Scale out if YARNMemoryAvailablePercentage is less than 15",
    "Action": {
      "SimpleScalingPolicyConfiguration": {
        "AdjustmentType": "CHANGE_IN_CAPACITY",
        "ScalingAdjustment": 1,
        "CoolDown": 300
      }
    },
    "Trigger": {
      "CloudWatchAlarmDefinition": {
        "ComparisonOperator": "LESS_THAN",
        "EvaluationPeriods": 1,
        "MetricName": "YARNMemoryAvailablePercentage",
        "Namespace": "AWS/ElasticMapReduce",
        "Period": 300,
        "Statistic": "AVERAGE",
        "Threshold": 15.0,
        "Unit": "PERCENT"
      }
    }
  }
]
}
`,
        bidPrice: "0.30",
        ebsConfigs: [{
            size: 40,
            type: "gp2",
            volumesPerInstance: 1,
        }],
        instanceCount: 1,
        instanceType: "c4.large",
    },
    ebsRootVolumeSize: 100,
    ec2Attributes: {
        emrManagedMasterSecurityGroup: aws_security_group_sg.id,
        emrManagedSlaveSecurityGroup: aws_security_group_sg.id,
        instanceProfile: aws_iam_instance_profile_emr_profile.arn,
        subnetId: aws_subnet_main.id,
    },
    keepJobFlowAliveWhenNoSteps: true,
    masterInstanceGroup: {
        instanceType: "m4.large",
    },
    releaseLabel: "emr-4.6.0",
    serviceRole: aws_iam_role_iam_emr_service_role.arn,
    tags: {
        env: "env",
        role: "rolename",
    },
    terminationProtection: false,
});
Enable Debug Logging
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.emr.Cluster("example", {
    steps: [{
        actionOnFailure: "TERMINATE_CLUSTER",
        hadoopJarStep: {
            args: ["state-pusher-script"],
            jar: "command-runner.jar",
        },
        name: "Setup Hadoop Debugging",
    }],
}, { ignoreChanges: ["stepConcurrencyLevel", "steps"] });
Multiple Node Master Instance Group
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

// Map public IP on launch must be enabled for public (Internet accessible) subnets
const exampleSubnet = new aws.ec2.Subnet("example", {
    mapPublicIpOnLaunch: true,
});
const exampleCluster = new aws.emr.Cluster("example", {
    // core_instance_group must be configured
    coreInstanceGroup: {},
    ec2Attributes: {
        subnetId: exampleSubnet.id,
    },
    masterInstanceGroup: {
        // Master instance count must be set to 3
        instanceCount: 3,
    },
    // EMR version must be 5.23.0 or later
    releaseLabel: "emr-5.24.1",
    // Termination protection is automatically enabled for multiple masters
    // To destroy the cluster, this must be configured to false and applied first
    terminationProtection: true,
});

Example bootable config

NOTE: This configuration demonstrates a minimal configuration needed to boot an example EMR Cluster. It is not meant to display best practices. Please use at your own risk.

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const mainVpc = new aws.ec2.Vpc("mainVpc", {
    cidrBlock: "168.31.0.0/16",
    enableDnsHostnames: true,
    tags: {
        name: "emr_test",
    },
});
const mainSubnet = new aws.ec2.Subnet("mainSubnet", {
    vpcId: mainVpc.id,
    cidrBlock: "168.31.0.0/20",
    tags: {
        name: "emr_test",
    },
});
// IAM role for EMR Service
const iamEmrServiceRole = new aws.iam.Role("iamEmrServiceRole", {assumeRolePolicy: `{
  "Version": "2008-10-17",
  "Statement": [
    {
      "Sid": "",
      "Effect": "Allow",
      "Principal": {
        "Service": "elasticmapreduce.amazonaws.com"
      },
      "Action": "sts:AssumeRole"
    }
  ]
}
`});
// IAM Role for EC2 Instance Profile
const iamEmrProfileRole = new aws.iam.Role("iamEmrProfileRole", {assumeRolePolicy: `{
  "Version": "2008-10-17",
  "Statement": [
    {
      "Sid": "",
      "Effect": "Allow",
      "Principal": {
        "Service": "ec2.amazonaws.com"
      },
      "Action": "sts:AssumeRole"
    }
  ]
}
`});
const emrProfile = new aws.iam.InstanceProfile("emrProfile", {roles: [iamEmrProfileRole.name]});
const cluster = new aws.emr.Cluster("cluster", {
    releaseLabel: "emr-4.6.0",
    applications: ["Spark"],
    ec2_attributes: {
        subnetId: mainSubnet.id,
        emrManagedMasterSecurityGroup: aws_security_group.allow_all.id,
        emrManagedSlaveSecurityGroup: aws_security_group.allow_all.id,
        instanceProfile: emrProfile.arn,
    },
    masterInstanceType: "m5.xlarge",
    coreInstanceType: "m5.xlarge",
    coreInstanceCount: 1,
    tags: {
        role: "rolename",
        dns_zone: "env_zone",
        env: "env",
        name: "name-env",
    },
    bootstrap_action: [{
        path: "s3://elasticmapreduce/bootstrap-actions/run-if",
        name: "runif",
        args: [
            "instance.isMaster=true",
            "echo running on master node",
        ],
    }],
    configurationsJson: `  [
    {
      "Classification": "hadoop-env",
      "Configurations": [
        {
          "Classification": "export",
          "Properties": {
            "JAVA_HOME": "/usr/lib/jvm/java-1.8.0"
          }
        }
      ],
      "Properties": {}
    },
    {
      "Classification": "spark-env",
      "Configurations": [
        {
          "Classification": "export",
          "Properties": {
            "JAVA_HOME": "/usr/lib/jvm/java-1.8.0"
          }
        }
      ],
      "Properties": {}
    }
  ]
`,
    serviceRole: iamEmrServiceRole.arn,
});
const allowAccess = new aws.ec2.SecurityGroup("allowAccess", {
    description: "Allow inbound traffic",
    vpcId: mainVpc.id,
    ingress: [{
        fromPort: 0,
        toPort: 0,
        protocol: "-1",
        cidrBlocks: mainVpc.cidrBlock,
    }],
    egress: [{
        fromPort: 0,
        toPort: 0,
        protocol: "-1",
        cidrBlocks: ["0.0.0.0/0"],
    }],
    tags: {
        name: "emr_test",
    },
});
const gw = new aws.ec2.InternetGateway("gw", {vpcId: mainVpc.id});
const routeTable = new aws.ec2.RouteTable("routeTable", {
    vpcId: mainVpc.id,
    route: [{
        cidrBlock: "0.0.0.0/0",
        gatewayId: gw.id,
    }],
});
const mainRouteTableAssociation = new aws.ec2.MainRouteTableAssociation("mainRouteTableAssociation", {
    vpcId: mainVpc.id,
    routeTableId: routeTable.id,
});
//##
const iamEmrServicePolicy = new aws.iam.RolePolicy("iamEmrServicePolicy", {
    role: iamEmrServiceRole.id,
    policy: `{
    "Version": "2012-10-17",
    "Statement": [{
        "Effect": "Allow",
        "Resource": "*",
        "Action": [
            "ec2:AuthorizeSecurityGroupEgress",
            "ec2:AuthorizeSecurityGroupIngress",
            "ec2:CancelSpotInstanceRequests",
            "ec2:CreateNetworkInterface",
            "ec2:CreateSecurityGroup",
            "ec2:CreateTags",
            "ec2:DeleteNetworkInterface",
            "ec2:DeleteSecurityGroup",
            "ec2:DeleteTags",
            "ec2:DescribeAvailabilityZones",
            "ec2:DescribeAccountAttributes",
            "ec2:DescribeDhcpOptions",
            "ec2:DescribeInstanceStatus",
            "ec2:DescribeInstances",
            "ec2:DescribeKeyPairs",
            "ec2:DescribeNetworkAcls",
            "ec2:DescribeNetworkInterfaces",
            "ec2:DescribePrefixLists",
            "ec2:DescribeRouteTables",
            "ec2:DescribeSecurityGroups",
            "ec2:DescribeSpotInstanceRequests",
            "ec2:DescribeSpotPriceHistory",
            "ec2:DescribeSubnets",
            "ec2:DescribeVpcAttribute",
            "ec2:DescribeVpcEndpoints",
            "ec2:DescribeVpcEndpointServices",
            "ec2:DescribeVpcs",
            "ec2:DetachNetworkInterface",
            "ec2:ModifyImageAttribute",
            "ec2:ModifyInstanceAttribute",
            "ec2:RequestSpotInstances",
            "ec2:RevokeSecurityGroupEgress",
            "ec2:RunInstances",
            "ec2:TerminateInstances",
            "ec2:DeleteVolume",
            "ec2:DescribeVolumeStatus",
            "ec2:DescribeVolumes",
            "ec2:DetachVolume",
            "iam:GetRole",
            "iam:GetRolePolicy",
            "iam:ListInstanceProfiles",
            "iam:ListRolePolicies",
            "iam:PassRole",
            "s3:CreateBucket",
            "s3:Get*",
            "s3:List*",
            "sdb:BatchPutAttributes",
            "sdb:Select",
            "sqs:CreateQueue",
            "sqs:Delete*",
            "sqs:GetQueue*",
            "sqs:PurgeQueue",
            "sqs:ReceiveMessage"
        ]
    }]
}
`,
});
const iamEmrProfilePolicy = new aws.iam.RolePolicy("iamEmrProfilePolicy", {
    role: iamEmrProfileRole.id,
    policy: `{
    "Version": "2012-10-17",
    "Statement": [{
        "Effect": "Allow",
        "Resource": "*",
        "Action": [
            "cloudwatch:*",
            "dynamodb:*",
            "ec2:Describe*",
            "elasticmapreduce:Describe*",
            "elasticmapreduce:ListBootstrapActions",
            "elasticmapreduce:ListClusters",
            "elasticmapreduce:ListInstanceGroups",
            "elasticmapreduce:ListInstances",
            "elasticmapreduce:ListSteps",
            "kinesis:CreateStream",
            "kinesis:DeleteStream",
            "kinesis:DescribeStream",
            "kinesis:GetRecords",
            "kinesis:GetShardIterator",
            "kinesis:MergeShards",
            "kinesis:PutRecord",
            "kinesis:SplitShard",
            "rds:Describe*",
            "s3:*",
            "sdb:*",
            "sns:*",
            "sqs:*"
        ]
    }]
}
`,
});

constructor

new Cluster(name: string, args: ClusterArgs, opts?: pulumi.CustomResourceOptions)

Create a Cluster 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?: ClusterState, opts?: pulumi.CustomResourceOptions): Cluster

Get an existing Cluster 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

public static isInstance(obj: any): obj is Cluster

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

property additionalInfo

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

A JSON string for selecting additional features such as adding proxy information. Note: Currently there is no API to retrieve the value of this argument after EMR cluster creation from provider, therefore this provider cannot detect drift from the actual EMR cluster if its value is changed outside this provider.

property applications

public applications: pulumi.Output<string[] | undefined>;

A list of applications for the cluster. Valid values are: Flink, Hadoop, Hive, Mahout, Pig, Spark, and JupyterHub (as of EMR 5.14.0). Case insensitive

property arn

public arn: pulumi.Output<string>;

property autoscalingRole

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

An IAM role for automatic scaling policies. The IAM role provides permissions that the automatic scaling feature requires to launch and terminate EC2 instances in an instance group.

property bootstrapActions

public bootstrapActions: pulumi.Output<ClusterBootstrapAction[] | undefined>;

Ordered list of bootstrap actions that will be run before Hadoop is started on the cluster nodes. Defined below.

property clusterState

public clusterState: pulumi.Output<string>;

property configurations

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

List of configurations supplied for the EMR cluster you are creating

property configurationsJson

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

A JSON string for supplying list of configurations for the EMR cluster.

property coreInstanceCount

DEPRECATED use core_instance_group configuration block instance_count argument instead
public coreInstanceCount: pulumi.Output<number>;

Use the coreInstanceGroup configuration block instanceCount argument instead. Number of Amazon EC2 instances used to execute the job flow. EMR will use one node as the cluster’s master node and use the remainder of the nodes (coreInstanceCount-1) as core nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set. Default 1

property coreInstanceGroup

public coreInstanceGroup: pulumi.Output<ClusterCoreInstanceGroup>;

Configuration block to use an Instance Group for the core node type. Cannot be specified if coreInstanceCount argument, coreInstanceType argument, or instanceGroup configuration blocks are set. Detailed below.

property coreInstanceType

DEPRECATED use core_instance_group configuration block instance_type argument instead
public coreInstanceType: pulumi.Output<string>;

Use the coreInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the slave nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set.

property customAmiId

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

A custom Amazon Linux AMI for the cluster (instead of an EMR-owned AMI). Available in Amazon EMR version 5.7.0 and later.

property ebsRootVolumeSize

public ebsRootVolumeSize: pulumi.Output<number | undefined>;

Size in GiB of the EBS root device volume of the Linux AMI that is used for each EC2 instance. Available in Amazon EMR version 4.x and later.

property ec2Attributes

public ec2Attributes: pulumi.Output<ClusterEc2Attributes | undefined>;

Attributes for the EC2 instances running the job flow. Defined below

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 instanceGroups

DEPRECATED use master_instance_group configuration block, core_instance_group configuration block, and aws_emr_instance_group resource(s) instead
public instanceGroups: pulumi.Output<ClusterInstanceGroup[]>;

Use the masterInstanceGroup configuration block, coreInstanceGroup configuration block and aws.emr.InstanceGroup resource(s) instead. A list of instanceGroup objects for each instance group in the cluster. Exactly one of masterInstanceType and instanceGroup must be specified. If instanceGroup is set, then it must contain a configuration block for at least the MASTER instance group type (as well as any additional instance groups). Cannot be specified if masterInstanceGroup or coreInstanceGroup configuration blocks are set. Defined below

property keepJobFlowAliveWhenNoSteps

public keepJobFlowAliveWhenNoSteps: pulumi.Output<boolean>;

Switch on/off run cluster with no steps or when all steps are complete (default is on)

property kerberosAttributes

public kerberosAttributes: pulumi.Output<ClusterKerberosAttributes | undefined>;

Kerberos configuration for the cluster. Defined below

property logUri

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

S3 bucket to write the log files of the job flow. If a value is not provided, logs are not created

property masterInstanceGroup

public masterInstanceGroup: pulumi.Output<ClusterMasterInstanceGroup>;

Configuration block to use an Instance Group for the master node type. Cannot be specified if masterInstanceType argument or instanceGroup configuration blocks are set. Detailed below.

property masterInstanceType

DEPRECATED use master_instance_group configuration block instance_type argument instead
public masterInstanceType: pulumi.Output<string>;

Use the masterInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the master node. Cannot be specified if masterInstanceGroup or instanceGroup configuration blocks are set.

property masterPublicDns

public masterPublicDns: pulumi.Output<string>;

The public DNS name of the master EC2 instance. * core_instance_group.0.id - Core node type Instance Group ID, if using Instance Group for this node type.

property name

public name: pulumi.Output<string>;

The name of the step.

property releaseLabel

public releaseLabel: pulumi.Output<string>;

The release label for the Amazon EMR release

property scaleDownBehavior

public scaleDownBehavior: pulumi.Output<string>;

The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized.

property securityConfiguration

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

The security configuration name to attach to the EMR cluster. Only valid for EMR clusters with releaseLabel 4.8.0 or greater

property serviceRole

public serviceRole: pulumi.Output<string>;

IAM role that will be assumed by the Amazon EMR service to access AWS resources

property stepConcurrencyLevel

public stepConcurrencyLevel: pulumi.Output<number | undefined>;

The number of steps that can be executed concurrently. You can specify a maximum of 256 steps. Only valid for EMR clusters with releaseLabel 5.28.0 or greater. (default is 1)

property steps

public steps: pulumi.Output<ClusterStep[]>;

List of steps to run when creating the cluster. Defined below. It is highly recommended to utilize ignoreChanges if other steps are being managed outside of this provider.

property tags

public tags: pulumi.Output<{[key: string]: any} | undefined>;

list of tags to apply to the EMR Cluster

property terminationProtection

public terminationProtection: pulumi.Output<boolean>;

Switch on/off termination protection (default is false, except when using multiple master nodes). Before attempting to destroy the resource when termination protection is enabled, this configuration must be applied with its value set to false.

property urn

urn: Output<URN>;

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

property visibleToAllUsers

public visibleToAllUsers: pulumi.Output<boolean | undefined>;

Whether the job flow is visible to all IAM users of the AWS account associated with the job flow. Default true

Resource InstanceGroup

class InstanceGroup extends CustomResource

Provides an Elastic MapReduce Cluster Instance Group configuration. See Amazon Elastic MapReduce Documentation for more information.

NOTE: At this time, Instance Groups cannot be destroyed through the API nor web interface. Instance Groups are destroyed when the EMR Cluster is destroyed. this provider will resize any Instance Group to zero when destroying the resource.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const task = new aws.emr.InstanceGroup("task", {
    clusterId: aws_emr_cluster_tf_test_cluster.id,
    instanceCount: 1,
    instanceType: "m5.xlarge",
});

constructor

new InstanceGroup(name: string, args: InstanceGroupArgs, opts?: pulumi.CustomResourceOptions)

Create a InstanceGroup 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?: InstanceGroupState, opts?: pulumi.CustomResourceOptions): InstanceGroup

Get an existing InstanceGroup 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

public static isInstance(obj: any): obj is InstanceGroup

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

property autoscalingPolicy

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

The autoscaling policy document. This is a JSON formatted string. See EMR Auto Scaling

property bidPrice

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

If set, the bid price for each EC2 instance in the instance group, expressed in USD. By setting this attribute, the instance group is being declared as a Spot Instance, and will implicitly create a Spot request. Leave this blank to use On-Demand Instances.

property clusterId

public clusterId: pulumi.Output<string>;

ID of the EMR Cluster to attach to. Changing this forces a new resource to be created.

property configurationsJson

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

A JSON string for supplying list of configurations specific to the EMR instance group. Note that this can only be changed when using EMR release 5.21 or later.

property ebsConfigs

public ebsConfigs: pulumi.Output<InstanceGroupEbsConfig[]>;

One or more ebsConfig blocks as defined below. Changing this forces a new resource to be created.

property ebsOptimized

public ebsOptimized: pulumi.Output<boolean | undefined>;

Indicates whether an Amazon EBS volume is EBS-optimized. Changing this forces a new resource to be created.

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 instanceCount

public instanceCount: pulumi.Output<number | undefined>;

target number of instances for the instance group. defaults to 0.

property instanceType

public instanceType: pulumi.Output<string>;

The EC2 instance type for all instances in the instance group. Changing this forces a new resource to be created.

property name

public name: pulumi.Output<string>;

Human friendly name given to the instance group. Changing this forces a new resource to be created.

property runningInstanceCount

public runningInstanceCount: pulumi.Output<number>;

property status

public status: pulumi.Output<string>;

property urn

urn: Output<URN>;

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

Resource SecurityConfiguration

class SecurityConfiguration extends CustomResource

Provides a resource to manage AWS EMR Security Configurations

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const foo = new aws.emr.SecurityConfiguration("foo", {
    configuration: `{
  "EncryptionConfiguration": {
    "AtRestEncryptionConfiguration": {
      "S3EncryptionConfiguration": {
        "EncryptionMode": "SSE-S3"
      },
      "LocalDiskEncryptionConfiguration": {
        "EncryptionKeyProviderType": "AwsKms",
        "AwsKmsKey": "arn:aws:kms:us-west-2:187416307283:alias/tf_emr_test_key"
      }
    },
    "EnableInTransitEncryption": false,
    "EnableAtRestEncryption": true
  }
}
`,
});

constructor

new SecurityConfiguration(name: string, args: SecurityConfigurationArgs, opts?: pulumi.CustomResourceOptions)

Create a SecurityConfiguration 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?: SecurityConfigurationState, opts?: pulumi.CustomResourceOptions): SecurityConfiguration

Get an existing SecurityConfiguration 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

public static isInstance(obj: any): obj is SecurityConfiguration

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

property configuration

public configuration: pulumi.Output<string>;

A JSON formatted Security Configuration

property creationDate

public creationDate: pulumi.Output<string>;

Date the Security Configuration was created

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>;

The name of the EMR Security Configuration. By default generated by this provider.

property namePrefix

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

Creates a unique name beginning with the specified prefix. Conflicts with name.

property urn

urn: Output<URN>;

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

Others

interface ClusterArgs

interface ClusterArgs

The set of arguments for constructing a Cluster resource.

property additionalInfo

additionalInfo?: pulumi.Input<string>;

A JSON string for selecting additional features such as adding proxy information. Note: Currently there is no API to retrieve the value of this argument after EMR cluster creation from provider, therefore this provider cannot detect drift from the actual EMR cluster if its value is changed outside this provider.

property applications

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

A list of applications for the cluster. Valid values are: Flink, Hadoop, Hive, Mahout, Pig, Spark, and JupyterHub (as of EMR 5.14.0). Case insensitive

property autoscalingRole

autoscalingRole?: pulumi.Input<string>;

An IAM role for automatic scaling policies. The IAM role provides permissions that the automatic scaling feature requires to launch and terminate EC2 instances in an instance group.

property bootstrapActions

bootstrapActions?: pulumi.Input<pulumi.Input<ClusterBootstrapAction>[]>;

Ordered list of bootstrap actions that will be run before Hadoop is started on the cluster nodes. Defined below.

property configurations

configurations?: pulumi.Input<string>;

List of configurations supplied for the EMR cluster you are creating

property configurationsJson

configurationsJson?: pulumi.Input<string>;

A JSON string for supplying list of configurations for the EMR cluster.

property coreInstanceCount

DEPRECATED use core_instance_group configuration block instance_count argument instead
coreInstanceCount?: pulumi.Input<number>;

Use the coreInstanceGroup configuration block instanceCount argument instead. Number of Amazon EC2 instances used to execute the job flow. EMR will use one node as the cluster’s master node and use the remainder of the nodes (coreInstanceCount-1) as core nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set. Default 1

property coreInstanceGroup

coreInstanceGroup?: pulumi.Input<ClusterCoreInstanceGroup>;

Configuration block to use an Instance Group for the core node type. Cannot be specified if coreInstanceCount argument, coreInstanceType argument, or instanceGroup configuration blocks are set. Detailed below.

property coreInstanceType

DEPRECATED use core_instance_group configuration block instance_type argument instead
coreInstanceType?: pulumi.Input<string>;

Use the coreInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the slave nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set.

property customAmiId

customAmiId?: pulumi.Input<string>;

A custom Amazon Linux AMI for the cluster (instead of an EMR-owned AMI). Available in Amazon EMR version 5.7.0 and later.

property ebsRootVolumeSize

ebsRootVolumeSize?: pulumi.Input<number>;

Size in GiB of the EBS root device volume of the Linux AMI that is used for each EC2 instance. Available in Amazon EMR version 4.x and later.

property ec2Attributes

ec2Attributes?: pulumi.Input<ClusterEc2Attributes>;

Attributes for the EC2 instances running the job flow. Defined below

property instanceGroups

DEPRECATED use master_instance_group configuration block, core_instance_group configuration block, and aws_emr_instance_group resource(s) instead
instanceGroups?: pulumi.Input<pulumi.Input<ClusterInstanceGroup>[]>;

Use the masterInstanceGroup configuration block, coreInstanceGroup configuration block and aws.emr.InstanceGroup resource(s) instead. A list of instanceGroup objects for each instance group in the cluster. Exactly one of masterInstanceType and instanceGroup must be specified. If instanceGroup is set, then it must contain a configuration block for at least the MASTER instance group type (as well as any additional instance groups). Cannot be specified if masterInstanceGroup or coreInstanceGroup configuration blocks are set. Defined below

property keepJobFlowAliveWhenNoSteps

keepJobFlowAliveWhenNoSteps?: pulumi.Input<boolean>;

Switch on/off run cluster with no steps or when all steps are complete (default is on)

property kerberosAttributes

kerberosAttributes?: pulumi.Input<ClusterKerberosAttributes>;

Kerberos configuration for the cluster. Defined below

property logUri

logUri?: pulumi.Input<string>;

S3 bucket to write the log files of the job flow. If a value is not provided, logs are not created

property masterInstanceGroup

masterInstanceGroup?: pulumi.Input<ClusterMasterInstanceGroup>;

Configuration block to use an Instance Group for the master node type. Cannot be specified if masterInstanceType argument or instanceGroup configuration blocks are set. Detailed below.

property masterInstanceType

DEPRECATED use master_instance_group configuration block instance_type argument instead
masterInstanceType?: pulumi.Input<string>;

Use the masterInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the master node. Cannot be specified if masterInstanceGroup or instanceGroup configuration blocks are set.

property name

name?: pulumi.Input<string>;

The name of the step.

property releaseLabel

releaseLabel: pulumi.Input<string>;

The release label for the Amazon EMR release

property scaleDownBehavior

scaleDownBehavior?: pulumi.Input<string>;

The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized.

property securityConfiguration

securityConfiguration?: pulumi.Input<string>;

The security configuration name to attach to the EMR cluster. Only valid for EMR clusters with releaseLabel 4.8.0 or greater

property serviceRole

serviceRole: pulumi.Input<string>;

IAM role that will be assumed by the Amazon EMR service to access AWS resources

property stepConcurrencyLevel

stepConcurrencyLevel?: pulumi.Input<number>;

The number of steps that can be executed concurrently. You can specify a maximum of 256 steps. Only valid for EMR clusters with releaseLabel 5.28.0 or greater. (default is 1)

property steps

steps?: pulumi.Input<pulumi.Input<ClusterStep>[]>;

List of steps to run when creating the cluster. Defined below. It is highly recommended to utilize ignoreChanges if other steps are being managed outside of this provider.

property tags

tags?: pulumi.Input<{[key: string]: any}>;

list of tags to apply to the EMR Cluster

property terminationProtection

terminationProtection?: pulumi.Input<boolean>;

Switch on/off termination protection (default is false, except when using multiple master nodes). Before attempting to destroy the resource when termination protection is enabled, this configuration must be applied with its value set to false.

property visibleToAllUsers

visibleToAllUsers?: pulumi.Input<boolean>;

Whether the job flow is visible to all IAM users of the AWS account associated with the job flow. Default true

interface ClusterState

interface ClusterState

Input properties used for looking up and filtering Cluster resources.

property additionalInfo

additionalInfo?: pulumi.Input<string>;

A JSON string for selecting additional features such as adding proxy information. Note: Currently there is no API to retrieve the value of this argument after EMR cluster creation from provider, therefore this provider cannot detect drift from the actual EMR cluster if its value is changed outside this provider.

property applications

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

A list of applications for the cluster. Valid values are: Flink, Hadoop, Hive, Mahout, Pig, Spark, and JupyterHub (as of EMR 5.14.0). Case insensitive

property arn

arn?: pulumi.Input<string>;

property autoscalingRole

autoscalingRole?: pulumi.Input<string>;

An IAM role for automatic scaling policies. The IAM role provides permissions that the automatic scaling feature requires to launch and terminate EC2 instances in an instance group.

property bootstrapActions

bootstrapActions?: pulumi.Input<pulumi.Input<ClusterBootstrapAction>[]>;

Ordered list of bootstrap actions that will be run before Hadoop is started on the cluster nodes. Defined below.

property clusterState

clusterState?: pulumi.Input<string>;

property configurations

configurations?: pulumi.Input<string>;

List of configurations supplied for the EMR cluster you are creating

property configurationsJson

configurationsJson?: pulumi.Input<string>;

A JSON string for supplying list of configurations for the EMR cluster.

property coreInstanceCount

DEPRECATED use core_instance_group configuration block instance_count argument instead
coreInstanceCount?: pulumi.Input<number>;

Use the coreInstanceGroup configuration block instanceCount argument instead. Number of Amazon EC2 instances used to execute the job flow. EMR will use one node as the cluster’s master node and use the remainder of the nodes (coreInstanceCount-1) as core nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set. Default 1

property coreInstanceGroup

coreInstanceGroup?: pulumi.Input<ClusterCoreInstanceGroup>;

Configuration block to use an Instance Group for the core node type. Cannot be specified if coreInstanceCount argument, coreInstanceType argument, or instanceGroup configuration blocks are set. Detailed below.

property coreInstanceType

DEPRECATED use core_instance_group configuration block instance_type argument instead
coreInstanceType?: pulumi.Input<string>;

Use the coreInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the slave nodes. Cannot be specified if coreInstanceGroup or instanceGroup configuration blocks are set.

property customAmiId

customAmiId?: pulumi.Input<string>;

A custom Amazon Linux AMI for the cluster (instead of an EMR-owned AMI). Available in Amazon EMR version 5.7.0 and later.

property ebsRootVolumeSize

ebsRootVolumeSize?: pulumi.Input<number>;

Size in GiB of the EBS root device volume of the Linux AMI that is used for each EC2 instance. Available in Amazon EMR version 4.x and later.

property ec2Attributes

ec2Attributes?: pulumi.Input<ClusterEc2Attributes>;

Attributes for the EC2 instances running the job flow. Defined below

property instanceGroups

DEPRECATED use master_instance_group configuration block, core_instance_group configuration block, and aws_emr_instance_group resource(s) instead
instanceGroups?: pulumi.Input<pulumi.Input<ClusterInstanceGroup>[]>;

Use the masterInstanceGroup configuration block, coreInstanceGroup configuration block and aws.emr.InstanceGroup resource(s) instead. A list of instanceGroup objects for each instance group in the cluster. Exactly one of masterInstanceType and instanceGroup must be specified. If instanceGroup is set, then it must contain a configuration block for at least the MASTER instance group type (as well as any additional instance groups). Cannot be specified if masterInstanceGroup or coreInstanceGroup configuration blocks are set. Defined below

property keepJobFlowAliveWhenNoSteps

keepJobFlowAliveWhenNoSteps?: pulumi.Input<boolean>;

Switch on/off run cluster with no steps or when all steps are complete (default is on)

property kerberosAttributes

kerberosAttributes?: pulumi.Input<ClusterKerberosAttributes>;

Kerberos configuration for the cluster. Defined below

property logUri

logUri?: pulumi.Input<string>;

S3 bucket to write the log files of the job flow. If a value is not provided, logs are not created

property masterInstanceGroup

masterInstanceGroup?: pulumi.Input<ClusterMasterInstanceGroup>;

Configuration block to use an Instance Group for the master node type. Cannot be specified if masterInstanceType argument or instanceGroup configuration blocks are set. Detailed below.

property masterInstanceType

DEPRECATED use master_instance_group configuration block instance_type argument instead
masterInstanceType?: pulumi.Input<string>;

Use the masterInstanceGroup configuration block instanceType argument instead. The EC2 instance type of the master node. Cannot be specified if masterInstanceGroup or instanceGroup configuration blocks are set.

property masterPublicDns

masterPublicDns?: pulumi.Input<string>;

The public DNS name of the master EC2 instance. * core_instance_group.0.id - Core node type Instance Group ID, if using Instance Group for this node type.

property name

name?: pulumi.Input<string>;

The name of the step.

property releaseLabel

releaseLabel?: pulumi.Input<string>;

The release label for the Amazon EMR release

property scaleDownBehavior

scaleDownBehavior?: pulumi.Input<string>;

The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized.

property securityConfiguration

securityConfiguration?: pulumi.Input<string>;

The security configuration name to attach to the EMR cluster. Only valid for EMR clusters with releaseLabel 4.8.0 or greater

property serviceRole

serviceRole?: pulumi.Input<string>;

IAM role that will be assumed by the Amazon EMR service to access AWS resources

property stepConcurrencyLevel

stepConcurrencyLevel?: pulumi.Input<number>;

The number of steps that can be executed concurrently. You can specify a maximum of 256 steps. Only valid for EMR clusters with releaseLabel 5.28.0 or greater. (default is 1)

property steps

steps?: pulumi.Input<pulumi.Input<ClusterStep>[]>;

List of steps to run when creating the cluster. Defined below. It is highly recommended to utilize ignoreChanges if other steps are being managed outside of this provider.

property tags

tags?: pulumi.Input<{[key: string]: any}>;

list of tags to apply to the EMR Cluster

property terminationProtection

terminationProtection?: pulumi.Input<boolean>;

Switch on/off termination protection (default is false, except when using multiple master nodes). Before attempting to destroy the resource when termination protection is enabled, this configuration must be applied with its value set to false.

property visibleToAllUsers

visibleToAllUsers?: pulumi.Input<boolean>;

Whether the job flow is visible to all IAM users of the AWS account associated with the job flow. Default true

interface InstanceGroupArgs

interface InstanceGroupArgs

The set of arguments for constructing a InstanceGroup resource.

property autoscalingPolicy

autoscalingPolicy?: pulumi.Input<string>;

The autoscaling policy document. This is a JSON formatted string. See EMR Auto Scaling

property bidPrice

bidPrice?: pulumi.Input<string>;

If set, the bid price for each EC2 instance in the instance group, expressed in USD. By setting this attribute, the instance group is being declared as a Spot Instance, and will implicitly create a Spot request. Leave this blank to use On-Demand Instances.

property clusterId

clusterId: pulumi.Input<string>;

ID of the EMR Cluster to attach to. Changing this forces a new resource to be created.

property configurationsJson

configurationsJson?: pulumi.Input<string>;

A JSON string for supplying list of configurations specific to the EMR instance group. Note that this can only be changed when using EMR release 5.21 or later.

property ebsConfigs

ebsConfigs?: pulumi.Input<pulumi.Input<InstanceGroupEbsConfig>[]>;

One or more ebsConfig blocks as defined below. Changing this forces a new resource to be created.

property ebsOptimized

ebsOptimized?: pulumi.Input<boolean>;

Indicates whether an Amazon EBS volume is EBS-optimized. Changing this forces a new resource to be created.

property instanceCount

instanceCount?: pulumi.Input<number>;

target number of instances for the instance group. defaults to 0.

property instanceType

instanceType: pulumi.Input<string>;

The EC2 instance type for all instances in the instance group. Changing this forces a new resource to be created.

property name

name?: pulumi.Input<string>;

Human friendly name given to the instance group. Changing this forces a new resource to be created.

interface InstanceGroupState

interface InstanceGroupState

Input properties used for looking up and filtering InstanceGroup resources.

property autoscalingPolicy

autoscalingPolicy?: pulumi.Input<string>;

The autoscaling policy document. This is a JSON formatted string. See EMR Auto Scaling

property bidPrice

bidPrice?: pulumi.Input<string>;

If set, the bid price for each EC2 instance in the instance group, expressed in USD. By setting this attribute, the instance group is being declared as a Spot Instance, and will implicitly create a Spot request. Leave this blank to use On-Demand Instances.

property clusterId

clusterId?: pulumi.Input<string>;

ID of the EMR Cluster to attach to. Changing this forces a new resource to be created.

property configurationsJson

configurationsJson?: pulumi.Input<string>;

A JSON string for supplying list of configurations specific to the EMR instance group. Note that this can only be changed when using EMR release 5.21 or later.

property ebsConfigs

ebsConfigs?: pulumi.Input<pulumi.Input<InstanceGroupEbsConfig>[]>;

One or more ebsConfig blocks as defined below. Changing this forces a new resource to be created.

property ebsOptimized

ebsOptimized?: pulumi.Input<boolean>;

Indicates whether an Amazon EBS volume is EBS-optimized. Changing this forces a new resource to be created.

property instanceCount

instanceCount?: pulumi.Input<number>;

target number of instances for the instance group. defaults to 0.

property instanceType

instanceType?: pulumi.Input<string>;

The EC2 instance type for all instances in the instance group. Changing this forces a new resource to be created.

property name

name?: pulumi.Input<string>;

Human friendly name given to the instance group. Changing this forces a new resource to be created.

property runningInstanceCount

runningInstanceCount?: pulumi.Input<number>;

property status

status?: pulumi.Input<string>;

interface SecurityConfigurationArgs

interface SecurityConfigurationArgs

The set of arguments for constructing a SecurityConfiguration resource.

property configuration

configuration: pulumi.Input<string>;

A JSON formatted Security Configuration

property name

name?: pulumi.Input<string>;

The name of the EMR Security Configuration. By default generated by this provider.

property namePrefix

namePrefix?: pulumi.Input<string>;

Creates a unique name beginning with the specified prefix. Conflicts with name.

interface SecurityConfigurationState

interface SecurityConfigurationState

Input properties used for looking up and filtering SecurityConfiguration resources.

property configuration

configuration?: pulumi.Input<string>;

A JSON formatted Security Configuration

property creationDate

creationDate?: pulumi.Input<string>;

Date the Security Configuration was created

property name

name?: pulumi.Input<string>;

The name of the EMR Security Configuration. By default generated by this provider.

property namePrefix

namePrefix?: pulumi.Input<string>;

Creates a unique name beginning with the specified prefix. Conflicts with name.