server_certificates
Creates, updates, deletes or gets a server_certificate
resource or lists server_certificates
in a region
Overview
Name | server_certificates |
Type | Resource |
Description | Resource Type definition for AWS::IAM::ServerCertificate |
Id | aws.iam.server_certificates |
Fields
Name | Datatype | Description |
---|---|---|
certificate_body | string | |
certificate_chain | string | |
server_certificate_name | string | |
path | string | |
private_key | string | |
arn | string | Amazon Resource Name (ARN) of the server certificate |
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 server_certificates
in a region.
SELECT
region,
certificate_body,
certificate_chain,
server_certificate_name,
path,
private_key,
arn,
tags
FROM aws.iam.server_certificates
;
Gets all properties from an individual server_certificate
.
SELECT
region,
certificate_body,
certificate_chain,
server_certificate_name,
path,
private_key,
arn,
tags
FROM aws.iam.server_certificates
WHERE data__Identifier = '<ServerCertificateName>';
INSERT
example
Use the following StackQL query and manifest file to create a new server_certificate
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.iam.server_certificates (
CertificateBody,
CertificateChain,
ServerCertificateName,
Path,
PrivateKey,
Tags,
region
)
SELECT
'{{ CertificateBody }}',
'{{ CertificateChain }}',
'{{ ServerCertificateName }}',
'{{ Path }}',
'{{ PrivateKey }}',
'{{ Tags }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.iam.server_certificates (
CertificateBody,
CertificateChain,
ServerCertificateName,
Path,
PrivateKey,
Tags,
region
)
SELECT
'{{ CertificateBody }}',
'{{ CertificateChain }}',
'{{ ServerCertificateName }}',
'{{ Path }}',
'{{ PrivateKey }}',
'{{ Tags }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: server_certificate
props:
- name: CertificateBody
value: '{{ CertificateBody }}'
- name: CertificateChain
value: '{{ CertificateChain }}'
- name: ServerCertificateName
value: '{{ ServerCertificateName }}'
- name: Path
value: '{{ Path }}'
- name: PrivateKey
value: '{{ PrivateKey }}'
- name: Tags
value:
- Value: '{{ Value }}'
Key: '{{ Key }}'
DELETE
example
/*+ delete */
DELETE FROM aws.iam.server_certificates
WHERE data__Identifier = '<ServerCertificateName>'
AND region = 'us-east-1';
Permissions
To operate on the server_certificates
resource, the following permissions are required:
Create
iam:UploadServerCertificate,
iam:TagServerCertificate,
iam:GetServerCertificate
Read
iam:GetServerCertificate
Update
iam:TagServerCertificate,
iam:UntagServerCertificate,
iam:ListServerCertificateTags,
iam:GetServerCertificate
Delete
iam:DeleteServerCertificate
List
iam:ListServerCertificates,
iam:GetServerCertificate