Skip to main content

environments

Creates, updates, deletes or gets an environment resource or lists environments in a region

Overview

Nameenvironments
TypeResource
DescriptionDefinition of AWS::DataZone::Environment Resource Type
Idawscc.datazone.environments

Fields

NameDatatypeDescription
aws_account_idstringThe AWS account in which the Amazon DataZone environment is created.
aws_account_regionstringThe AWS region in which the Amazon DataZone environment is created.
environment_account_identifierstringThe AWS account in which the Amazon DataZone environment is created.
environment_account_regionstringThe AWS region in which the Amazon DataZone environment is created.
created_atstringThe timestamp of when the environment was created.
created_bystringThe Amazon DataZone user who created the environment.
descriptionstringThe description of the Amazon DataZone environment.
domain_idstringThe identifier of the Amazon DataZone domain in which the environment is created.
domain_identifierstringThe identifier of the Amazon DataZone domain in which the environment would be created.
environment_blueprint_idstringThe ID of the blueprint with which the Amazon DataZone environment was created.
environment_profile_idstringThe ID of the environment profile with which the Amazon DataZone environment was created.
environment_profile_identifierstringThe ID of the environment profile with which the Amazon DataZone environment would be created.
glossary_termsarrayThe glossary terms that can be used in the Amazon DataZone environment.
environment_role_arnstringEnvironment role arn for custom aws environment permissions
idstringThe ID of the Amazon DataZone environment.
namestringThe name of the environment.
project_idstringThe ID of the Amazon DataZone project in which the environment is created.
project_identifierstringThe ID of the Amazon DataZone project in which the environment would be created.
providerstringThe provider of the Amazon DataZone environment.
statusstringThe status of the Amazon DataZone environment.
updated_atstringThe timestamp of when the environment was updated.
user_parametersarrayThe user parameters of the Amazon DataZone environment.
regionstringAWS region.

For more information, see AWS::DataZone::Environment.

Methods

NameResourceAccessible byRequired Params
create_resourceenvironmentsINSERTName, ProjectIdentifier, DomainIdentifier, region
delete_resourceenvironmentsDELETEIdentifier, region
update_resourceenvironmentsUPDATEIdentifier, PatchDocument, region
list_resourcesenvironments_list_onlySELECTregion
get_resourceenvironmentsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual environment.

SELECT
region,
aws_account_id,
aws_account_region,
environment_account_identifier,
environment_account_region,
created_at,
created_by,
description,
domain_id,
domain_identifier,
environment_blueprint_id,
environment_profile_id,
environment_profile_identifier,
glossary_terms,
environment_role_arn,
id,
name,
project_id,
project_identifier,
provider,
status,
updated_at,
user_parameters
FROM awscc.datazone.environments
WHERE
region = 'us-east-1' AND
Identifier = '{{ domain_id }}|{{ id }}';

INSERT example

Use the following StackQL query and manifest file to create a new environment resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.datazone.environments (
DomainIdentifier,
Name,
ProjectIdentifier,
region
)
SELECT
'{{ domain_identifier }}',
'{{ name }}',
'{{ project_identifier }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a environment resource, using stack-deploy.

/*+ update */
UPDATE awscc.datazone.environments
SET PatchDocument = string('{{ {
"Description": description,
"GlossaryTerms": glossary_terms,
"EnvironmentRoleArn": environment_role_arn,
"Name": name
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_id }}|{{ id }}';

DELETE example

/*+ delete */
DELETE FROM awscc.datazone.environments
WHERE
Identifier = '{{ domain_id }}|{{ id }}' AND
region = 'us-east-1';

Permissions

To operate on the environments resource, the following permissions are required:

datazone:CreateEnvironment,
datazone:GetEnvironment,
datazone:DeleteEnvironment,
datazone:AssociateEnvironmentRole,
iam:PassRole