Can we turn off Cloudwatch logs when running ecs:execute-command API?

0

We log into our containers from time to time using execute-command and notice that all our activities get logged directly to CloudWatch.

Is there any way to stop your activity logs from going to CloudWatch when using the execute-command api? This could easily result in leaking secrets from environment variables as you innocently go about checking things ...

2 個答案
2

Hi, you can turn off the logging of the execute-command session by setting the logging option of your cluster to NONE.

https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-exec.html#ecs-exec-logging

profile picture
HS
已回答 8 個月前
profile picture
專家
已審閱 8 個月前
profile pictureAWS
專家
已審閱 8 個月前
0

Hello.

Modify your log driver https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_LogConfiguration.html to adjust the logging configuration. He supports various logging drivers, such as json-file, awslogs etc. You can configure the logging driver to meet your specific needs.

Best regards, Andrii

profile picture
專家
已回答 8 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南