From bfe871698c0c11b309f8cfe46fdf848a93ec5b77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?nils=20m=C3=A5s=C3=A9n?= Date: Sat, 12 Aug 2023 18:39:45 +0200 Subject: [PATCH] add additional docs regarding secret usage --- docs/arguments.md | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/docs/arguments.md b/docs/arguments.md index 6ce1921..f74b102 100644 --- a/docs/arguments.md +++ b/docs/arguments.md @@ -27,6 +27,33 @@ In the example above, watchtower will execute an upgrade attempt on the containe When no arguments are specified, watchtower will monitor all running containers. +## Secrets/Files + +Some arguments can also reference a file, in which case the contents of the file are used as the value. +This can be used to avoid putting secrets in the configuration file or command line. + +The following arguments are currently supported (including their corresponding `WATCHTOWER_` environment variables): + - `notification-url` + - `notification-email-server-password` + - `notification-slack-hook-url` + - `notification-msteams-hook` + - `notification-gotify-token` + - `http-api-token` + +### Example docker-compose usage +```yaml +secrets: + access_token: + file: access_token + +services: + watchtower: + secrets: + - access_token + environment: + - WATCHTOWER_HTTP_API_TOKEN=/run/secrets/access_token +``` + ## Help Shows documentation about the supported flags. @@ -364,4 +391,4 @@ requests and may rate limit pull requests (mainly docker.io). Environment Variable: WATCHTOWER_WARN_ON_HEAD_FAILURE Possible values: always, auto, never Default: auto -``` \ No newline at end of file +```