sites
Creates, updates, deletes or gets a site
resource or lists sites
in a region
Overview
Name | sites |
Type | Resource |
Description | The AWS::NetworkManager::Site type describes a site. |
Id | aws.networkmanager.sites |
Fields
Name | Datatype | Description |
---|---|---|
site_arn | string | The Amazon Resource Name (ARN) of the site. |
site_id | string | The ID of the site. |
description | string | The description of the site. |
tags | array | The tags for the site. |
global_network_id | string | The ID of the global network. |
location | object | The location of the site. |
created_at | string | The date and time that the device was created. |
state | string | The state of the site. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | GlobalNetworkId, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all sites
in a region.
SELECT
region,
site_arn,
site_id,
description,
tags,
global_network_id,
location,
created_at,
state
FROM aws.networkmanager.sites
WHERE region = 'us-east-1';
Gets all properties from an individual site
.
SELECT
region,
site_arn,
site_id,
description,
tags,
global_network_id,
location,
created_at,
state
FROM aws.networkmanager.sites
WHERE region = 'us-east-1' AND data__Identifier = '<GlobalNetworkId>|<SiteId>';
INSERT
example
Use the following StackQL query and manifest file to create a new site
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.networkmanager.sites (
GlobalNetworkId,
region
)
SELECT
'{{ GlobalNetworkId }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.networkmanager.sites (
Description,
Tags,
GlobalNetworkId,
Location,
region
)
SELECT
'{{ Description }}',
'{{ Tags }}',
'{{ GlobalNetworkId }}',
'{{ Location }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: site
props:
- name: Description
value: '{{ Description }}'
- name: Tags
value:
- Key: '{{ Key }}'
Value: '{{ Value }}'
- name: GlobalNetworkId
value: '{{ GlobalNetworkId }}'
- name: Location
value:
Address: '{{ Address }}'
Latitude: '{{ Latitude }}'
Longitude: '{{ Longitude }}'
DELETE
example
/*+ delete */
DELETE FROM aws.networkmanager.sites
WHERE data__Identifier = '<GlobalNetworkId|SiteId>'
AND region = 'us-east-1';
Permissions
To operate on the sites
resource, the following permissions are required:
Create
networkmanager:CreateSite,
networkmanager:GetSites,
networkmanager:TagResource
Read
networkmanager:GetSites
Update
networkmanager:GetSites,
networkmanager:ListTagsForResource,
networkmanager:TagResource,
networkmanager:UntagResource,
networkmanager:UpdateSite
Delete
networkmanager:GetSites,
networkmanager:DeleteSite
List
networkmanager:GetSites