account_settings
Creates, updates, deletes, gets or lists an account_settings resource.
Overview
| Name | account_settings |
| Type | Resource |
| Id | aws.ecs.account_settings |
Fields
The following fields are returned by SELECT queries:
- list_account_settings
| Name | Datatype | Description |
|---|---|---|
name | string | The Amazon ECS resource name. (serviceLongArnFormat, taskLongArnFormat, containerInstanceLongArnFormat, awsvpcTrunking, containerInsights, fargateFIPSMode, tagResourceAuthorization, fargateTaskRetirementWaitPeriod, guardDutyActivate, defaultLogDriverMode, fargateEventWindows) |
principal_arn | string | The ARN of the principal. It can be a user, role, or the root user. If this field is omitted, the authenticated user is assumed. |
type_ | string | Indicates whether Amazon Web Services manages the account setting, or if the user manages it. aws_managed account settings are read-only, as Amazon Web Services manages such on the customer's behalf. Currently, the guardDutyActivate account setting is the only one Amazon Web Services manages. (user, aws_managed) |
value | string | Determines whether the account setting is on or off for the specified resource. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list_account_settings | select | region | Lists the account settings for a specified principal. | |
put_account_setting | replace | region, name, value | Modifies an account setting. Account settings are set on a per-Region basis. If you change the root user account setting, the default settings are reset for users and roles that do not have specified individual account settings. For more information, see Account Settings in the Amazon Elastic Container Service Developer Guide. | |
delete_account_setting | delete | region | Disables an account setting for a specified user, role, or the root user for an account. | |
put_account_setting_default | exec | region, name, value | Modifies an account setting for all users on an account for whom no individual account setting has been specified. Account settings are set on a per-Region basis. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- list_account_settings
Lists the account settings for a specified principal.
SELECT
name,
principal_arn,
type_,
value
FROM aws.ecs.account_settings
WHERE region = '{{ region }}' -- required
;
REPLACE examples
- put_account_setting
Modifies an account setting. Account settings are set on a per-Region basis. If you change the root user account setting, the default settings are reset for users and roles that do not have specified individual account settings. For more information, see Account Settings in the Amazon Elastic Container Service Developer Guide.
REPLACE aws.ecs.account_settings
SET
name = '{{ name }}',
value = '{{ value }}',
principalArn = '{{ principalArn }}'
WHERE
region = '{{ region }}' --required
AND name = '{{ name }}' --required
AND value = '{{ value }}' --required
RETURNING
setting;
DELETE examples
- delete_account_setting
Disables an account setting for a specified user, role, or the root user for an account.
DELETE FROM aws.ecs.account_settings
WHERE region = '{{ region }}' --required
;
Lifecycle Methods
- put_account_setting_default
Modifies an account setting for all users on an account for whom no individual account setting has been specified. Account settings are set on a per-Region basis.
EXEC aws.ecs.account_settings.put_account_setting_default
@region='{{ region }}' --required
@@json=
'{
"name": "{{ name }}",
"value": "{{ value }}"
}'
;