UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

123 lines 5.08 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.Capability = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Manages an EKS Capability for an EKS cluster. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.eks.Capability("example", { * clusterName: exampleAwsEksCluster.name, * capabilityName: "argocd", * type: "ARGOCD", * roleArn: exampleAwsIamRole.arn, * deletePropagationPolicy: "RETAIN", * configuration: { * argoCd: { * awsIdc: { * idcInstanceArn: "arn:aws:sso:::instance/ssoins-1234567890abcdef0", * }, * namespace: "argocd", * }, * }, * tags: { * Name: "example-capability", * }, * }); * ``` * * ## Import * * Using `pulumi import`, import EKS Capability using the `cluster_name` and `capability_name` separated by a comma (`,`). For example: * * ```sh * $ pulumi import aws:eks/capability:Capability example my-cluster,my-capability * ``` */ class Capability extends pulumi.CustomResource { /** * Get an existing Capability resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name, id, state, opts) { return new Capability(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of Capability. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === Capability.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["arn"] = state?.arn; resourceInputs["capabilityName"] = state?.capabilityName; resourceInputs["clusterName"] = state?.clusterName; resourceInputs["configuration"] = state?.configuration; resourceInputs["deletePropagationPolicy"] = state?.deletePropagationPolicy; resourceInputs["region"] = state?.region; resourceInputs["roleArn"] = state?.roleArn; resourceInputs["tags"] = state?.tags; resourceInputs["tagsAll"] = state?.tagsAll; resourceInputs["timeouts"] = state?.timeouts; resourceInputs["type"] = state?.type; resourceInputs["version"] = state?.version; } else { const args = argsOrState; if (args?.capabilityName === undefined && !opts.urn) { throw new Error("Missing required property 'capabilityName'"); } if (args?.clusterName === undefined && !opts.urn) { throw new Error("Missing required property 'clusterName'"); } if (args?.deletePropagationPolicy === undefined && !opts.urn) { throw new Error("Missing required property 'deletePropagationPolicy'"); } if (args?.roleArn === undefined && !opts.urn) { throw new Error("Missing required property 'roleArn'"); } if (args?.type === undefined && !opts.urn) { throw new Error("Missing required property 'type'"); } resourceInputs["capabilityName"] = args?.capabilityName; resourceInputs["clusterName"] = args?.clusterName; resourceInputs["configuration"] = args?.configuration; resourceInputs["deletePropagationPolicy"] = args?.deletePropagationPolicy; resourceInputs["region"] = args?.region; resourceInputs["roleArn"] = args?.roleArn; resourceInputs["tags"] = args?.tags; resourceInputs["timeouts"] = args?.timeouts; resourceInputs["type"] = args?.type; resourceInputs["arn"] = undefined /*out*/; resourceInputs["tagsAll"] = undefined /*out*/; resourceInputs["version"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(Capability.__pulumiType, name, resourceInputs, opts); } } exports.Capability = Capability; /** @internal */ Capability.__pulumiType = 'aws:eks/capability:Capability'; //# sourceMappingURL=capability.js.map