fargate_profiles
Creates, updates, deletes or gets a fargate_profile resource or lists fargate_profiles in a region
Overview
| Name | fargate_profiles |
| Type | Resource |
| Description | Resource Schema for AWS::EKS::FargateProfile |
| Id | awscc.eks.fargate_profiles |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
cluster_name | string | Name of the Cluster |
fargate_profile_name | string | Name of FargateProfile |
pod_execution_role_arn | string | The IAM policy arn for pods |
arn | string | |
subnets | array | |
selectors | array | |
tags | array | An array of key-value pairs to apply to this resource. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
cluster_name | string | Name of the Cluster |
fargate_profile_name | string | Name of FargateProfile |
region | string | AWS region. |
For more information, see AWS::EKS::FargateProfile.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | fargate_profiles | INSERT | ClusterName, PodExecutionRoleArn, Selectors, region |
delete_resource | fargate_profiles | DELETE | Identifier, region |
update_resource | fargate_profiles | UPDATE | Identifier, PatchDocument, region |
list_resources | fargate_profiles_list_only | SELECT | region |
get_resource | fargate_profiles | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual fargate_profile.
SELECT
region,
cluster_name,
fargate_profile_name,
pod_execution_role_arn,
arn,
subnets,
selectors,
tags
FROM awscc.eks.fargate_profiles
WHERE
region = 'us-east-1' AND
Identifier = '{{ cluster_name }}|{{ fargate_profile_name }}';
Lists all fargate_profiles in a region.
SELECT
region,
cluster_name,
fargate_profile_name
FROM awscc.eks.fargate_profiles_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new fargate_profile resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.eks.fargate_profiles (
ClusterName,
PodExecutionRoleArn,
Selectors,
region
)
SELECT
'{{ cluster_name }}',
'{{ pod_execution_role_arn }}',
'{{ selectors }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.eks.fargate_profiles (
ClusterName,
FargateProfileName,
PodExecutionRoleArn,
Subnets,
Selectors,
Tags,
region
)
SELECT
'{{ cluster_name }}',
'{{ fargate_profile_name }}',
'{{ pod_execution_role_arn }}',
'{{ subnets }}',
'{{ selectors }}',
'{{ tags }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: fargate_profile
props:
- name: cluster_name
value: '{{ cluster_name }}'
- name: fargate_profile_name
value: '{{ fargate_profile_name }}'
- name: pod_execution_role_arn
value: '{{ pod_execution_role_arn }}'
- name: subnets
value:
- '{{ subnets[0] }}'
- name: selectors
value:
- namespace: '{{ namespace }}'
labels:
- key: '{{ key }}'
value: '{{ value }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a fargate_profile resource, using stack-deploy.
/*+ update */
UPDATE awscc.eks.fargate_profiles
SET PatchDocument = string('{{ {
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ cluster_name }}|{{ fargate_profile_name }}';
DELETE example
/*+ delete */
DELETE FROM awscc.eks.fargate_profiles
WHERE
Identifier = '{{ cluster_name }}|{{ fargate_profile_name }}' AND
region = 'us-east-1';
Permissions
To operate on the fargate_profiles resource, the following permissions are required:
- Create
- Read
- Delete
- List
- Update
eks:CreateFargateProfile,
eks:DescribeFargateProfile,
iam:GetRole,
iam:PassRole,
iam:CreateServiceLinkedRole,
eks:TagResource
eks:DescribeFargateProfile
eks:DeleteFargateProfile,
eks:DescribeFargateProfile
eks:ListFargateProfiles
eks:DescribeFargateProfile,
eks:TagResource,
eks:UntagResource