SaarlandProgger
SaarlandProgger

Reputation: 49

Aws Ecs Taskdefinition - Setup Docker Logrotation

i want to create a task definition in aws to run my docker container in Aws Ecs. I want to pass options like

--log-opt max-size=10m --log-opt max-file=5

Anyone an idea how I can pass this commands through the task definition?

Thanks

Upvotes: 0

Views: 209

Answers (1)

dimisjim
dimisjim

Reputation: 425

From the documentation found here & here you can find the way to define these in the ECS task definition.

For example, you can define the key-values that you want, in the options object, like:

"logConfiguration": {
    ...
    "options": {
        "max-size": "10m",
        "max-file": "5",
    },
    ...
}

Upvotes: 1

Related Questions