containers
Creates, updates, deletes, gets or lists a containers resource.
Overview
| Name | containers |
| Type | Resource |
| Id | aws.mediastore.containers |
Fields
The following fields are returned by SELECT queries:
- describe_container
- list_containers
| Name | Datatype | Description |
|---|---|---|
arn | string | The Amazon Resource Name (ARN) of the container. The ARN has the following format: arn:aws:<region>:<account that owns this container>:container/<name of container> For example: arn:aws:mediastore:us-west-2:111122223333:container/movies (pattern: <code>arn:aws:mediastore:[a-z]+-[a-z]+-\d:\d{12}:container/[\w-]{1,255}</code>) |
access_logging_enabled | boolean | The state of access logging on the container. This value is false by default, indicating that AWS Elemental MediaStore does not send access logs to Amazon CloudWatch Logs. When you enable access logging on the container, MediaStore changes this value to true, indicating that the service delivers access logs for objects stored in that container to CloudWatch Logs. |
creation_time | string (date-time) | Unix timestamp. |
endpoint | string | The DNS endpoint of the container. Use the endpoint to identify the specific container when sending requests to the data plane. The service assigns this value when the container is created. Once the value has been assigned, it does not change. (pattern: <code>[\u0009\u000A\u000D\u0020-\u00FF]+</code>) |
name | string | The name of the container. (pattern: <code>[\w-]+</code>) |
status | string | The status of container creation or deletion. The status is one of the following: CREATING, ACTIVE, or DELETING. While the service is creating the container, the status is CREATING. When the endpoint is available, the status changes to ACTIVE. (ACTIVE, CREATING, DELETING) |
| Name | Datatype | Description |
|---|---|---|
arn | string | The Amazon Resource Name (ARN) of the container. The ARN has the following format: arn:aws:<region>:<account that owns this container>:container/<name of container> For example: arn:aws:mediastore:us-west-2:111122223333:container/movies (pattern: <code>arn:aws:mediastore:[a-z]+-[a-z]+-\d:\d{12}:container/[\w-]{1,255}</code>) |
access_logging_enabled | boolean | The state of access logging on the container. This value is false by default, indicating that AWS Elemental MediaStore does not send access logs to Amazon CloudWatch Logs. When you enable access logging on the container, MediaStore changes this value to true, indicating that the service delivers access logs for objects stored in that container to CloudWatch Logs. |
creation_time | string (date-time) | Unix timestamp. |
endpoint | string | The DNS endpoint of the container. Use the endpoint to identify the specific container when sending requests to the data plane. The service assigns this value when the container is created. Once the value has been assigned, it does not change. (pattern: <code>[\u0009\u000A\u000D\u0020-\u00FF]+</code>) |
name | string | The name of the container. (pattern: <code>[\w-]+</code>) |
status | string | The status of container creation or deletion. The status is one of the following: CREATING, ACTIVE, or DELETING. While the service is creating the container, the status is CREATING. When the endpoint is available, the status changes to ACTIVE. (ACTIVE, CREATING, DELETING) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_container | select | region | Retrieves the properties of the requested container. This request is commonly used to retrieve the endpoint of a container. An endpoint is a value assigned by the service when a new container is created. A container's endpoint does not change after it has been assigned. The DescribeContainer request returns a single Container object based on ContainerName. To return all Container objects that are associated with a specified AWS account, use ListContainers. | |
list_containers | select | region | Lists the properties of all containers in AWS Elemental MediaStore. You can query to receive all the containers in one response. Or you can include the MaxResults parameter to receive a limited number of containers in each response. In this case, the response includes a token. To get the next set of containers, send the command again, this time with the NextToken parameter (with the returned token as its value). The next set of responses appears, with a token if there are still more containers to receive. See also DescribeContainer, which gets the properties of one container. | |
create_container | insert | region, ContainerName | Creates a storage container to hold objects. A container is similar to a bucket in the Amazon S3 service. | |
delete_container | delete | region | Deletes the specified container. Before you make a DeleteContainer request, delete any objects in the container or in any folders in the container. You can delete only empty containers. | |
start_access_logging | exec | region, ContainerName | Starts access logging on the specified container. When you enable access logging on a container, MediaStore delivers access logs for objects stored in that container to Amazon CloudWatch Logs. | |
stop_access_logging | exec | region, ContainerName | Stops access logging on the specified container. When you stop access logging on a container, MediaStore stops sending access logs to Amazon CloudWatch Logs. These access logs are not saved and are not retrievable. |
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_container
- list_containers
Retrieves the properties of the requested container. This request is commonly used to retrieve the endpoint of a container. An endpoint is a value assigned by the service when a new container is created. A container's endpoint does not change after it has been assigned. The DescribeContainer request returns a single Container object based on ContainerName. To return all Container objects that are associated with a specified AWS account, use ListContainers.
SELECT
arn,
access_logging_enabled,
creation_time,
endpoint,
name,
status
FROM aws.mediastore.containers
WHERE region = '{{ region }}' -- required
;
Lists the properties of all containers in AWS Elemental MediaStore. You can query to receive all the containers in one response. Or you can include the MaxResults parameter to receive a limited number of containers in each response. In this case, the response includes a token. To get the next set of containers, send the command again, this time with the NextToken parameter (with the returned token as its value). The next set of responses appears, with a token if there are still more containers to receive. See also DescribeContainer, which gets the properties of one container.
SELECT
arn,
access_logging_enabled,
creation_time,
endpoint,
name,
status
FROM aws.mediastore.containers
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_container
- Manifest
Creates a storage container to hold objects. A container is similar to a bucket in the Amazon S3 service.
INSERT INTO aws.mediastore.containers (
ContainerName,
Tags,
region
)
SELECT
'{{ ContainerName }}' /* required */,
'{{ Tags }}',
'{{ region }}'
RETURNING
container
;
# Description fields are for documentation purposes
- name: containers
props:
- name: region
value: "{{ region }}"
description: Required parameter for the containers resource.
- name: ContainerName
value: "{{ ContainerName }}"
description: |
The name for the container. The name must be from 1 to 255 characters. Container names must be unique to your AWS account within a specific region. As an example, you could create a container named movies in every region, as long as you don’t have an existing container with that name.
- name: Tags
description: |
An array of key:value pairs that you define. These values can be anything that you want. Typically, the tag key represents a category (such as "environment") and the tag value represents a specific value within that category (such as "test," "development," or "production"). You can add up to 50 tags to each container. For more information about tagging, including naming and usage conventions, see Tagging Resources in MediaStore.
value:
- Key: "{{ Key }}"
Value: "{{ Value }}"
DELETE examples
- delete_container
Deletes the specified container. Before you make a DeleteContainer request, delete any objects in the container or in any folders in the container. You can delete only empty containers.
DELETE FROM aws.mediastore.containers
WHERE region = '{{ region }}' --required
;
Lifecycle Methods
- start_access_logging
- stop_access_logging
Starts access logging on the specified container. When you enable access logging on a container, MediaStore delivers access logs for objects stored in that container to Amazon CloudWatch Logs.
EXEC aws.mediastore.containers.start_access_logging
@region='{{ region }}' --required
@@json=
'{
"ContainerName": "{{ ContainerName }}"
}'
;
Stops access logging on the specified container. When you stop access logging on a container, MediaStore stops sending access logs to Amazon CloudWatch Logs. These access logs are not saved and are not retrievable.
EXEC aws.mediastore.containers.stop_access_logging
@region='{{ region }}' --required
@@json=
'{
"ContainerName": "{{ ContainerName }}"
}'
;