module_versions
Creates, updates, deletes or gets a module_version
resource or lists module_versions
in a region
Overview
Name | module_versions |
Type | Resource |
Description | A module that has been registered in the CloudFormation registry. |
Id | aws.cloudformation.module_versions |
Fields
Name | Datatype | Description |
---|---|---|
arn | string | The Amazon Resource Name (ARN) of the module. |
description | string | The description of the registered module. |
documentation_url | string | The URL of a page providing detailed documentation for this module. |
module_name | string | The name of the module being registered. Recommended module naming pattern: company_or_organization::service::type::MODULE. |
module_package | string | The url to the S3 bucket containing the schema and template fragment for the module you want to register. |
is_default_version | boolean | Indicator of whether this module version is the current default version |
schema | string | The schema defining input parameters to and resources generated by the module. |
time_created | string | The time that the specified module version was registered. |
version_id | string | The version ID of the module represented by this module instance. |
visibility | string | The scope at which the type is visible and usable in CloudFormation operations. The only allowed value at present is: PRIVATE: The type is only visible and usable within the account in which it is registered. Currently, AWS CloudFormation marks any types you register as PRIVATE. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | ModuleName, ModulePackage, region |
delete_resource | DELETE | data__Identifier, region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all properties from an individual module_version
.
SELECT
region,
arn,
description,
documentation_url,
module_name,
module_package,
is_default_version,
schema,
time_created,
version_id,
visibility
FROM aws.cloudformation.module_versions
WHERE region = 'us-east-1' AND data__Identifier = '<Arn>';
INSERT
example
Use the following StackQL query and manifest file to create a new module_version
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.cloudformation.module_versions (
ModuleName,
ModulePackage,
region
)
SELECT
'{{ ModuleName }}',
'{{ ModulePackage }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.cloudformation.module_versions (
ModuleName,
ModulePackage,
region
)
SELECT
'{{ ModuleName }}',
'{{ ModulePackage }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: module_version
props:
- name: ModuleName
value: '{{ ModuleName }}'
- name: ModulePackage
value: '{{ ModulePackage }}'
DELETE
example
/*+ delete */
DELETE FROM aws.cloudformation.module_versions
WHERE data__Identifier = '<Arn>'
AND region = 'us-east-1';
Permissions
To operate on the module_versions
resource, the following permissions are required:
Create
cloudformation:DescribeType,
cloudformation:DescribeTypeRegistration,
cloudformation:ListTypeVersions,
cloudformation:RegisterType,
s3:GetObject,
s3:ListBucket
Read
cloudformation:DescribeType
Delete
cloudformation:DeregisterType,
cloudformation:DescribeType