sematext / sematext-agent-docker

Sematext Docker Agent - host + container metrics, logs & event collector
https://sematext.com/docker
Apache License 2.0
209 stars 30 forks source link

Add support / docs for using Docker Secrets #25

Closed otisg closed 7 years ago

otisg commented 7 years ago

Or maybe this is already doable?

otisg commented 7 years ago

It looks like this can be done now, so closing.

megastef commented 7 years ago

A short documentation is in the README. Search for "secrets". The path/filename for docker secrets could be changed e.g. via -e CONFIG_FILE=/run/secrets/my-sda-secret-config.
An alternative is to use the docker service create command to change the name of the secret file in the container e.g.

docker service create --secret source=my-sda-secret-config,target=sematext-agent  ...

to match the default file name /run/secrets/sematext-agent. I'll add the docker command to the documentation.