UNPKG

@pulumi/aws

Version:

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

134 lines 6.53 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.Environment = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Resource for managing an AWS DataZone Environment. * * ## Example Usage * * ### Basic Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.datazone.Environment("example", { * name: "example", * accountIdentifier: test.accountId, * accountRegion: testAwsRegion.name, * blueprintIdentifier: testAwsDatazoneEnvironmentBlueprintConfiguration.environmentBlueprintId, * profileIdentifier: testAwsDatazoneEnvironmentProfile.id, * projectIdentifier: testAwsDatazoneProject.id, * domainIdentifier: testAwsDatazoneDomain.id, * userParameters: [ * { * name: "consumerGlueDbName", * value: "consumer", * }, * { * name: "producerGlueDbName", * value: "producer", * }, * { * name: "workgroupName", * value: "workgroup", * }, * ], * }); * ``` * * ## Import * * Using `pulumi import`, import DataZone Environment using the `domain_idntifier,id`. For example: * * ```sh * $ pulumi import aws:datazone/environment:Environment example dzd_d2i7tzk3tnjjf4,5vpywijpwryec0 * ``` */ class Environment extends pulumi.CustomResource { /** * Get an existing Environment 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 Environment(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of Environment. 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'] === Environment.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["accountIdentifier"] = state ? state.accountIdentifier : undefined; resourceInputs["accountRegion"] = state ? state.accountRegion : undefined; resourceInputs["blueprintIdentifier"] = state ? state.blueprintIdentifier : undefined; resourceInputs["createdAt"] = state ? state.createdAt : undefined; resourceInputs["createdBy"] = state ? state.createdBy : undefined; resourceInputs["description"] = state ? state.description : undefined; resourceInputs["domainIdentifier"] = state ? state.domainIdentifier : undefined; resourceInputs["glossaryTerms"] = state ? state.glossaryTerms : undefined; resourceInputs["lastDeployments"] = state ? state.lastDeployments : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["profileIdentifier"] = state ? state.profileIdentifier : undefined; resourceInputs["projectIdentifier"] = state ? state.projectIdentifier : undefined; resourceInputs["providerEnvironment"] = state ? state.providerEnvironment : undefined; resourceInputs["provisionedResources"] = state ? state.provisionedResources : undefined; resourceInputs["region"] = state ? state.region : undefined; resourceInputs["timeouts"] = state ? state.timeouts : undefined; resourceInputs["userParameters"] = state ? state.userParameters : undefined; } else { const args = argsOrState; if ((!args || args.domainIdentifier === undefined) && !opts.urn) { throw new Error("Missing required property 'domainIdentifier'"); } if ((!args || args.profileIdentifier === undefined) && !opts.urn) { throw new Error("Missing required property 'profileIdentifier'"); } if ((!args || args.projectIdentifier === undefined) && !opts.urn) { throw new Error("Missing required property 'projectIdentifier'"); } resourceInputs["accountIdentifier"] = args ? args.accountIdentifier : undefined; resourceInputs["accountRegion"] = args ? args.accountRegion : undefined; resourceInputs["blueprintIdentifier"] = args ? args.blueprintIdentifier : undefined; resourceInputs["description"] = args ? args.description : undefined; resourceInputs["domainIdentifier"] = args ? args.domainIdentifier : undefined; resourceInputs["glossaryTerms"] = args ? args.glossaryTerms : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["profileIdentifier"] = args ? args.profileIdentifier : undefined; resourceInputs["projectIdentifier"] = args ? args.projectIdentifier : undefined; resourceInputs["region"] = args ? args.region : undefined; resourceInputs["timeouts"] = args ? args.timeouts : undefined; resourceInputs["userParameters"] = args ? args.userParameters : undefined; resourceInputs["createdAt"] = undefined /*out*/; resourceInputs["createdBy"] = undefined /*out*/; resourceInputs["lastDeployments"] = undefined /*out*/; resourceInputs["providerEnvironment"] = undefined /*out*/; resourceInputs["provisionedResources"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(Environment.__pulumiType, name, resourceInputs, opts); } } exports.Environment = Environment; /** @internal */ Environment.__pulumiType = 'aws:datazone/environment:Environment'; //# sourceMappingURL=environment.js.map