mirror of https://github.com/docker/cli.git
ec3daea021
Due to a typo, substitution would not work if the given environment-variable was set. Given the following docker compose file; ```yaml version: "3.7" services: app: image: nginx:${version:-latest} ``` Deploying a stack with `$version` set would ignore the `$version` environment variable, and use the default value instead; ```bash version=alpine docker stack deploy -c docker-compose.yml foobar Creating network foobar_default Creating service foobar_app docker service ls ID NAME MODE REPLICAS IMAGE PORTS rskkjxe6sm0w foobar_app replicated 1/1 nginx:latest ``` This patch also fixes "soft default" not detecting empty environment variables, only non-set environment variables. Signed-off-by: Sebastiaan van Stijn <github@gone.nl> |
||
---|---|---|
.. | ||
template.go | ||
template_test.go |