regions
Creates, updates, deletes, gets or lists a regions resource.
Overview
| Name | regions |
| Type | Resource |
| Id | aws.ds.regions |
Fields
The following fields are returned by SELECT queries:
- describe_regions
| Name | Datatype | Description |
|---|---|---|
desired_number_of_domain_controllers | integer | The desired number of domain controllers in the specified Region for the specified directory. |
directory_id | string | The identifier of the directory. (pattern: <code>^d-[0-9a-f]{10}$</code>) |
last_updated_date_time | string (date-time) | The date and time that the Region description was last updated. |
launch_time | string (date-time) | Specifies when the Region replication began. |
region_name | string | The name of the Region. For example, us-east-1. |
region_type | string | Specifies whether the Region is the primary Region or an additional Region. (Primary, Additional) |
status | string | The status of the replication process for the specified Region. (Requested, Creating, Created, Active, Inoperable, Impaired, Restoring, RestoreFailed, Deleting, Deleted, Failed, Updating) |
status_last_updated_date_time | string (date-time) | The date and time that the Region status was last updated. |
vpc_settings | object | Contains VPC information for the CreateDirectory, CreateMicrosoftAD, or CreateHybridAD operation. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_regions | select | region | Provides information about the Regions that are configured for multi-Region replication. | |
add_region | update | region, DirectoryId, RegionName, VPCSettings | Adds two domain controllers in the specified Region for the specified directory. | |
remove_region | update | region, DirectoryId | Stops all replication and removes the domain controllers from the specified Region. You cannot remove the primary Region with this operation. Instead, use the DeleteDirectory API. |
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
- describe_regions
Provides information about the Regions that are configured for multi-Region replication.
SELECT
desired_number_of_domain_controllers,
directory_id,
last_updated_date_time,
launch_time,
region_name,
region_type,
status,
status_last_updated_date_time,
vpc_settings
FROM aws.ds.regions
WHERE region = '{{ region }}' -- required
;
UPDATE examples
- add_region
- remove_region
Adds two domain controllers in the specified Region for the specified directory.
UPDATE aws.ds.regions
SET
DirectoryId = '{{ DirectoryId }}',
RegionName = '{{ RegionName }}',
VPCSettings = '{{ VPCSettings }}'
WHERE
region = '{{ region }}' --required
AND DirectoryId = '{{ DirectoryId }}' --required
AND RegionName = '{{ RegionName }}' --required
AND VPCSettings = '{{ VPCSettings }}' --required;
Stops all replication and removes the domain controllers from the specified Region. You cannot remove the primary Region with this operation. Instead, use the DeleteDirectory API.
UPDATE aws.ds.regions
SET
DirectoryId = '{{ DirectoryId }}'
WHERE
region = '{{ region }}' --required
AND DirectoryId = '{{ DirectoryId }}' --required;