logging ¶
In AWS ECS you can define the log driver in a similar way as you do locally. In ECS Compose-X, default settings will be applied and use awslogs driver by default.
For more information on the docker-compose logging syntax, refer to Docker Compose logging syntax reference
docker-compose options ¶
Currently, the settings defined in
logging
are ignored and replaced by default settings for AWS Logs.
This is to guarantee deployment success on AWS ECS with AWS Fargate. Future versions will cater for other logging drivers.
You can however update options with logging if you defined the logging driver as
awslogs
Tip
For more configuration options with ECS Compose-X, see services.x-logging or firelens_syntax_reference
awslogs ¶
Option Name |
Required |
Notes/Features |
---|---|---|
awslogs-create-group |
False |
Compose-X creates a new log group by default |
awslogs-region |
True |
When specified, Compose-X only handles IAM to grant. If not set, defaults to AWS::Region |
awslogs-endpoint |
False |
|
awslogs-group |
True |
Defaults to family name when unset |
awslogs-stream-prefix |
True |
Defaults to service name when unset |
awslogs-datetime-format |
False |
|
awslogs-multiline-pattern |
False |
|
mode |
False |
|
max-buffer-size |
False |
Hint
To set the log retention period, you can use services.x-logging or x-aws-logs_retention