{"action":"created","issue":{"url":"https://api.github.com/repos/docker/cli/issues/1392","repository_url":"https://api.github.com/repos/docker/cli","labels_url":"https://api.github.com/repos/docker/cli/issues/1392/labels{/name}","comments_url":"https://api.github.com/repos/docker/cli/issues/1392/comments","events_url":"https://api.github.com/repos/docker/cli/issues/1392/events","html_url":"https://github.com/docker/cli/pull/1392","id":363668899,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE4MDQ2OTY0","number":1392,"title":"Fix substitution with non-empty env-var","user":{"login":"thaJeztah","id":1804568,"node_id":"MDQ6VXNlcjE4MDQ1Njg=","avatar_url":"https://avatars2.githubusercontent.com/u/1804568?v=4","gravatar_id":"","url":"https://api.github.com/users/thaJeztah","html_url":"https://github.com/thaJeztah","followers_url":"https://api.github.com/users/thaJeztah/followers","following_url":"https://api.github.com/users/thaJeztah/following{/other_user}","gists_url":"https://api.github.com/users/thaJeztah/gists{/gist_id}","starred_url":"https://api.github.com/users/thaJeztah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thaJeztah/subscriptions","organizations_url":"https://api.github.com/users/thaJeztah/orgs","repos_url":"https://api.github.com/users/thaJeztah/repos","events_url":"https://api.github.com/users/thaJeztah/events{/privacy}","received_events_url":"https://api.github.com/users/thaJeztah/received_events","type":"User","site_admin":false},"labels":[{"id":617717114,"node_id":"MDU6TGFiZWw2MTc3MTcxMTQ=","url":"https://api.github.com/repos/docker/cli/labels/area/stack","name":"area/stack","color":"fef2c0","default":false},{"id":585916071,"node_id":"MDU6TGFiZWw1ODU5MTYwNzE=","url":"https://api.github.com/repos/docker/cli/labels/status/2-code-review","name":"status/2-code-review","color":"fad8c7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-09-25T16:40:30Z","updated_at":"2018-09-25T17:59:57Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/docker/cli/pulls/1392","html_url":"https://github.com/docker/cli/pull/1392","diff_url":"https://github.com/docker/cli/pull/1392.diff","patch_url":"https://github.com/docker/cli/pull/1392.patch"},"body":"fixes https://github.com/docker/cli/issues/1391\r\n\r\nDue to a typo introduced in https://github.com/docker/cli/pull/1249, substitution would not work if the given environment-variable was set.\r\n\r\nGiven the following docker compose file;\r\n\r\n```yaml\r\nversion: \"3.7\"\r\n\r\nservices:\r\n  app:\r\n    image: nginx:${version:-latest}\r\n```\r\n\r\nDeploying a stack with `$version` set would ignore the `$version`\r\nenvironment variable, and use the default value instead;\r\n\r\n```bash\r\nversion=alpine docker stack deploy -c docker-compose.yml foobar\r\n\r\nCreating network foobar_default\r\nCreating service foobar_app\r\n\r\ndocker service ls\r\n\r\nID                  NAME                MODE                REPLICAS            IMAGE               PORTS\r\nrskkjxe6sm0w        foobar_app          replicated          1/1                 nginx:latest\r\n```\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/docker/cli/issues/comments/424442230","html_url":"https://github.com/docker/cli/pull/1392#issuecomment-424442230","issue_url":"https://api.github.com/repos/docker/cli/issues/1392","id":424442230,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNDQ0MjIzMA==","user":{"login":"thaJeztah","id":1804568,"node_id":"MDQ6VXNlcjE4MDQ1Njg=","avatar_url":"https://avatars2.githubusercontent.com/u/1804568?v=4","gravatar_id":"","url":"https://api.github.com/users/thaJeztah","html_url":"https://github.com/thaJeztah","followers_url":"https://api.github.com/users/thaJeztah/followers","following_url":"https://api.github.com/users/thaJeztah/following{/other_user}","gists_url":"https://api.github.com/users/thaJeztah/gists{/gist_id}","starred_url":"https://api.github.com/users/thaJeztah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thaJeztah/subscriptions","organizations_url":"https://api.github.com/users/thaJeztah/orgs","repos_url":"https://api.github.com/users/thaJeztah/repos","events_url":"https://api.github.com/users/thaJeztah/events{/privacy}","received_events_url":"https://api.github.com/users/thaJeztah/received_events","type":"User","site_admin":false},"created_at":"2018-09-25T17:59:57Z","updated_at":"2018-09-25T17:59:57Z","author_association":"MEMBER","body":"Looks like the \"soft default\" doesn't actually check for empty values, so that's an existing bug as well (which went unnoticed because we never reached that part).\r\n\r\nI'll have a look after dinner 😅 "}}
{"actor":{"display_login":"thaJeztah"}}