I want to use AWS CloudWatch logs in a Kubernetes cluster, where each pod contains a few Docker containers, each deployment would have a separate Log Group, and each container would have a separate stream.
I could not find a way to send the logging parameters to the docker containers via Kubernetes create / apply.
How can I send the log-driver and log-opt parameters to a Docker container in a pod / deployment?
Setting an AWS CloudWatch Logs driver in docker is done with log-driver=awslogs and log-opt, for example -
docker run \
--log-opt awslogs-region=eu-central-1 \
--log-opt awslogs-group=whatever-group \
--log-opt awslogs-stream=whatever-stream \
--log-opt awslogs-create-group=true \
Can anyone helP?