service_networks
Creates, updates, deletes or gets a service_network
resource or lists service_networks
in a region
Overview
Name | service_networks |
Type | Resource |
Description | A service network is a logical boundary for a collection of services. You can associate services and VPCs with a service network. |
Id | aws.vpclattice.service_networks |
Fields
Name | Datatype | Description |
---|---|---|
arn | string | |
created_at | string | |
id | string | |
last_updated_at | string | |
name | string | |
auth_type | string | |
tags | array | |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | 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 service_networks
in a region.
SELECT
region,
arn,
created_at,
id,
last_updated_at,
name,
auth_type,
tags
FROM aws.vpclattice.service_networks
WHERE region = 'us-east-1';
Gets all properties from an individual service_network
.
SELECT
region,
arn,
created_at,
id,
last_updated_at,
name,
auth_type,
tags
FROM aws.vpclattice.service_networks
WHERE region = 'us-east-1' AND data__Identifier = '<Arn>';
INSERT
example
Use the following StackQL query and manifest file to create a new service_network
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.vpclattice.service_networks (
Name,
AuthType,
Tags,
region
)
SELECT
'{{ Name }}',
'{{ AuthType }}',
'{{ Tags }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.vpclattice.service_networks (
Name,
AuthType,
Tags,
region
)
SELECT
'{{ Name }}',
'{{ AuthType }}',
'{{ Tags }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: service_network
props:
- name: Name
value: '{{ Name }}'
- name: AuthType
value: '{{ AuthType }}'
- name: Tags
value:
- Key: '{{ Key }}'
Value: '{{ Value }}'
DELETE
example
/*+ delete */
DELETE FROM aws.vpclattice.service_networks
WHERE data__Identifier = '<Arn>'
AND region = 'us-east-1';
Permissions
To operate on the service_networks
resource, the following permissions are required:
Create
vpc-lattice:GetServiceNetwork,
vpc-lattice:ListTagsForResource,
vpc-lattice:CreateServiceNetwork,
vpc-lattice:TagResource,
iam:CreateServiceLinkedRole
Read
vpc-lattice:GetServiceNetwork,
vpc-lattice:ListTagsForResource
Update
vpc-lattice:GetServiceNetwork,
vpc-lattice:UpdateServiceNetwork,
vpc-lattice:TagResource,
vpc-lattice:UntagResource
Delete
vpc-lattice:DeleteServiceNetwork
List
vpc-lattice:ListServiceNetworks