live_sources
Creates, updates, deletes or gets a live_source resource or lists live_sources in a region
Overview
| Name | live_sources |
| Type | Resource |
| Description | Definition of AWS::MediaTailor::LiveSource Resource Type |
| Id | awscc.mediatailor.live_sources |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
arn | string | The ARN of the live source. |
http_package_configurations | array | A list of HTTP package configuration parameters for this live source. |
live_source_name | string | |
source_location_name | string | |
tags | array | The tags to assign to the live source. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
live_source_name | string | |
source_location_name | string | |
region | string | AWS region. |
For more information, see AWS::MediaTailor::LiveSource.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | live_sources | INSERT | HttpPackageConfigurations, LiveSourceName, SourceLocationName, region |
delete_resource | live_sources | DELETE | Identifier, region |
update_resource | live_sources | UPDATE | Identifier, PatchDocument, region |
list_resources | live_sources_list_only | SELECT | region |
get_resource | live_sources | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual live_source.
SELECT
region,
arn,
http_package_configurations,
live_source_name,
source_location_name,
tags
FROM awscc.mediatailor.live_sources
WHERE
region = '{{ region }}' AND
Identifier = '{{ live_source_name }}|{{ source_location_name }}';
Lists all live_sources in a region.
SELECT
region,
live_source_name,
source_location_name
FROM awscc.mediatailor.live_sources_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new live_source resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.mediatailor.live_sources (
HttpPackageConfigurations,
LiveSourceName,
SourceLocationName,
region
)
SELECT
'{{ http_package_configurations }}',
'{{ live_source_name }}',
'{{ source_location_name }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.mediatailor.live_sources (
HttpPackageConfigurations,
LiveSourceName,
SourceLocationName,
Tags,
region
)
SELECT
'{{ http_package_configurations }}',
'{{ live_source_name }}',
'{{ source_location_name }}',
'{{ tags }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: live_source
props:
- name: http_package_configurations
value:
- path: '{{ path }}'
source_group: '{{ source_group }}'
type: '{{ type }}'
- name: live_source_name
value: '{{ live_source_name }}'
- name: source_location_name
value: '{{ source_location_name }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a live_source resource, using stack-deploy.
/*+ update */
UPDATE awscc.mediatailor.live_sources
SET PatchDocument = string('{{ {
"HttpPackageConfigurations": http_package_configurations,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ live_source_name }}|{{ source_location_name }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.mediatailor.live_sources
WHERE
Identifier = '{{ live_source_name }}|{{ source_location_name }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the live_sources resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
mediatailor:CreateLiveSource,
mediatailor:DescribeLiveSource,
mediatailor:TagResource
mediatailor:DescribeLiveSource
mediatailor:UpdateLiveSource,
mediatailor:DescribeLiveSource,
mediatailor:TagResource,
mediatailor:UntagResource
mediatailor:DeleteLiveSource,
mediatailor:DescribeLiveSource
mediatailor:ListLiveSources