[
StrictOps
control plane
How It WorksPricingSecurityDocs
Log InGet Started
StrictOps Docs

Logs

Viewing application logs in StrictOps

Logs

StrictOps provides access to your application logs through CloudWatch Logs integration. You can view logs directly in the StrictOps console or query them via the API.

How Logs Work

When your application runs on ECS Fargate:

  1. Container stdout/stderr is captured by the ECS agent
  2. Logs are sent to CloudWatch Logs in your AWS account
  3. StrictOps queries CloudWatch using your AWS connection
  4. Logs are displayed in the console or returned via API

Log Organization

Logs are organized by:

DimensionDescription
Stack IDCloudFormation stack identifier
ServiceService name from strictops.yml
EnvironmentDeployment environment (production, staging, etc.)
ContainerIndividual container instance

Querying Logs

Required Parameters

ParameterDescription
stackIdCloudFormation stack ID (from deployment)
roleArnAWS IAM role ARN for cross-account access
externalIdExternal ID for role assumption

Optional Parameters

ParameterDescriptionDefault
regionAWS regionus-east-1
startTimeStart time (Unix timestamp in ms)Last 15 minutes
endTimeEnd time (Unix timestamp in ms)Now
filterPatternCloudWatch filter patternNone
limitMaximum log events to return100
nextTokenPagination tokenNone

Filter Patterns

You can filter logs using CloudWatch filter pattern syntax:

PatternMatches
ERRORLines containing "ERROR"
"Connection refused"Lines containing the exact phrase
?ERROR ?WARNLines containing "ERROR" or "WARN"
[timestamp, level=ERROR, ...]Structured log parsing

See CloudWatch filter pattern syntax for full documentation.

Pagination

Large log queries return paginated results:

  1. First request returns logs and a nextToken
  2. Pass nextToken in subsequent requests to get more logs
  3. When nextToken is null, all logs have been retrieved

Log Retention

Log retention is configured in your AWS account's CloudWatch settings. StrictOps does not modify retention policies. The default ECS log retention is 30 days.

Viewing Logs in the Console

The StrictOps console provides a log viewer for each deployment:

  1. Navigate to your deployment
  2. Click the "Logs" tab
  3. Use the time range selector and filter input
  4. Logs stream in real-time for running deployments

API Reference

See the Logs API in Swagger for endpoint details and request/response schemas.

Relationship to Other Entities

  • Deployments provide the stackId needed to query logs
  • AWS Connection provides credentials to access CloudWatch
  • Services determine log group naming
  • Environments separate log groups for each environment

On this page