Skip to main content

container_logs

Creates, updates, deletes, gets or lists a container_logs resource.

Overview

Namecontainer_logs
TypeResource
Idaws.lightsail.container_logs

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
log_eventsarrayAn array of objects that describe the log events of a container.
next_page_tokenstringThe token to advance to the next page of results from your request. A next page token is not returned if there are no more results to display. To get the next page of results, perform another GetContainerLog request and specify the next page token using the pageToken parameter.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_container_logselectregionReturns the log events of a container of your Amazon Lightsail container service. If your container service has more than one node (i.e., a scale greater than 1), then the log events that are returned for the specified container are merged from all nodes on your container service. Container logs are retained for a certain amount of time. For more information, see Amazon Lightsail endpoints and quotas in the Amazon Web Services General Reference.

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.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Returns the log events of a container of your Amazon Lightsail container service. If your container service has more than one node (i.e., a scale greater than 1), then the log events that are returned for the specified container are merged from all nodes on your container service. Container logs are retained for a certain amount of time. For more information, see Amazon Lightsail endpoints and quotas in the Amazon Web Services General Reference.

SELECT
log_events,
next_page_token
FROM aws.lightsail.container_logs
WHERE region = '{{ region }}' -- required
;