core_networks
Creates, updates, deletes or gets a core_network resource or lists core_networks in a region
Overview
| Name | core_networks |
| Type | Resource |
| Description | AWS::NetworkManager::CoreNetwork Resource Type Definition. |
| Id | awscc.networkmanager.core_networks |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
global_network_id | string | The ID of the global network that your core network is a part of. |
core_network_id | string | The Id of core network |
core_network_arn | string | The ARN (Amazon resource name) of core network |
policy_document | object | Live policy document for the core network, you must provide PolicyDocument in Json Format |
description | string | The description of core network |
created_at | string | The creation time of core network |
state | string | The state of core network |
segments | array | The segments within a core network. |
network_function_groups | array | The network function groups within a core network. |
edges | array | The edges within a core network. |
owner_account | string | Owner of the core network |
tags | array | The tags for the global network. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
core_network_id | string | The Id of core network |
region | string | AWS region. |
For more information, see AWS::NetworkManager::CoreNetwork.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | core_networks | INSERT | GlobalNetworkId, region |
delete_resource | core_networks | DELETE | Identifier, region |
update_resource | core_networks | UPDATE | Identifier, PatchDocument, region |
list_resources | core_networks_list_only | SELECT | region |
get_resource | core_networks | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual core_network.
SELECT
region,
global_network_id,
core_network_id,
core_network_arn,
policy_document,
description,
created_at,
state,
segments,
network_function_groups,
edges,
owner_account,
tags
FROM awscc.networkmanager.core_networks
WHERE
region = 'us-east-1' AND
Identifier = '{{ core_network_id }}';
Lists all core_networks in a region.
SELECT
region,
core_network_id
FROM awscc.networkmanager.core_networks_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new core_network resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.networkmanager.core_networks (
GlobalNetworkId,
region
)
SELECT
'{{ global_network_id }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.networkmanager.core_networks (
GlobalNetworkId,
PolicyDocument,
Description,
Tags,
region
)
SELECT
'{{ global_network_id }}',
'{{ policy_document }}',
'{{ description }}',
'{{ tags }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: core_network
props:
- name: global_network_id
value: '{{ global_network_id }}'
- name: policy_document
value: {}
- name: description
value: '{{ description }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a core_network resource, using stack-deploy.
/*+ update */
UPDATE awscc.networkmanager.core_networks
SET PatchDocument = string('{{ {
"PolicyDocument": policy_document,
"Description": description,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ core_network_id }}';
DELETE example
/*+ delete */
DELETE FROM awscc.networkmanager.core_networks
WHERE
Identifier = '{{ core_network_id }}' AND
region = 'us-east-1';
Permissions
To operate on the core_networks resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
networkmanager:CreateCoreNetwork,
networkmanager:GetCoreNetwork,
networkmanager:GetCoreNetworkPolicy,
networkmanager:TagResource,
ec2:DescribeRegions
networkmanager:GetCoreNetwork,
networkmanager:GetCoreNetworkPolicy
networkmanager:UpdateCoreNetwork,
networkmanager:GetCoreNetwork,
networkmanager:ListTagsForResource,
networkmanager:PutCoreNetworkPolicy,
networkmanager:GetCoreNetworkPolicy,
networkmanager:ExecuteCoreNetworkChangeSet,
networkmanager:TagResource,
networkmanager:UntagResource,
ec2:DescribeRegions
networkmanager:DeleteCoreNetwork,
networkmanager:UntagResource,
networkmanager:GetCoreNetwork,
networkmanager:GetCoreNetworkPolicy,
ec2:DescribeRegions
networkmanager:ListCoreNetworks