{"action":"created","issue":{"url":"https://api.github.com/repos/docker/docker/issues/25338","repository_url":"https://api.github.com/repos/docker/docker","labels_url":"https://api.github.com/repos/docker/docker/issues/25338/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/25338/comments","events_url":"https://api.github.com/repos/docker/docker/issues/25338/events","html_url":"https://github.com/docker/docker/issues/25338","id":168933336,"number":25338,"title":"--publish-rm on service update should error if the port isn't a target port","user":{"login":"jhorwit2","id":3876739,"avatar_url":"https://avatars.githubusercontent.com/u/3876739?v=3","gravatar_id":"","url":"https://api.github.com/users/jhorwit2","html_url":"https://github.com/jhorwit2","followers_url":"https://api.github.com/users/jhorwit2/followers","following_url":"https://api.github.com/users/jhorwit2/following{/other_user}","gists_url":"https://api.github.com/users/jhorwit2/gists{/gist_id}","starred_url":"https://api.github.com/users/jhorwit2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jhorwit2/subscriptions","organizations_url":"https://api.github.com/users/jhorwit2/orgs","repos_url":"https://api.github.com/users/jhorwit2/repos","events_url":"https://api.github.com/users/jhorwit2/events{/privacy}","received_events_url":"https://api.github.com/users/jhorwit2/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/docker/docker/labels/area/cli","name":"area/cli","color":"fbca04"},{"url":"https://api.github.com/repos/docker/docker/labels/area/swarm","name":"area/swarm","color":"fbca04"},{"url":"https://api.github.com/repos/docker/docker/labels/kind/enhancement","name":"kind/enhancement","color":"E8CAAF"},{"url":"https://api.github.com/repos/docker/docker/labels/version/1.12","name":"version/1.12","color":"ededed"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/docker/docker/milestones/56","html_url":"https://github.com/docker/docker/milestones/1.13.0","labels_url":"https://api.github.com/repos/docker/docker/milestones/56/labels","id":1839404,"number":56,"title":"1.13.0","description":"","creator":{"login":"thaJeztah","id":1804568,"avatar_url":"https://avatars.githubusercontent.com/u/1804568?v=3","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},"open_issues":71,"closed_issues":96,"state":"open","created_at":"2016-06-20T22:51:25Z","updated_at":"2016-08-18T20:10:48Z","due_on":null,"closed_at":null},"comments":10,"created_at":"2016-08-02T16:45:03Z","updated_at":"2016-08-19T01:17:48Z","closed_at":null,"body":"<!--\r\nIf you are reporting a new issue, make sure that we do not have any duplicates\r\nalready open. You can ensure this by searching the issue list for this\r\nrepository. If there is a duplicate, please close your issue and add a comment\r\nto the existing issue instead.\r\n\r\nIf you suspect your issue is a bug, please edit your issue description to\r\ninclude the BUG REPORT INFORMATION shown below. If you fail to provide this\r\ninformation within 7 days, we cannot debug your issue and will close it. We\r\nwill, however, reopen it if you later provide the information.\r\n\r\nFor more information about reporting issues, see\r\nhttps://github.com/docker/docker/blob/master/CONTRIBUTING.md#reporting-other-issues\r\n\r\n---------------------------------------------------\r\nBUG REPORT INFORMATION\r\n---------------------------------------------------\r\nUse the commands below to provide key information from your environment:\r\nYou do NOT have to include this information if this is a FEATURE REQUEST\r\n-->\r\n\r\n**Output of `docker version`:**\r\n\r\n```\r\nClient:\r\n Version:      1.12.0\r\n API version:  1.24\r\n Go version:   go1.6.3\r\n Git commit:   8eab29e\r\n Built:        Thu Jul 28 21:15:28 2016\r\n OS/Arch:      darwin/amd64\r\n\r\nServer:\r\n Version:      1.12.0\r\n API version:  1.24\r\n Go version:   go1.6.3\r\n Git commit:   8eab29e\r\n Built:        Thu Jul 28 21:15:28 2016\r\n OS/Arch:      linux/amd64\r\n```\r\n\r\n\r\n**Output of `docker info`:**\r\n\r\n```\r\nContainers: 20\r\n Running: 3\r\n Paused: 0\r\n Stopped: 17\r\nImages: 223\r\nServer Version: 1.12.0\r\nStorage Driver: aufs\r\n Root Dir: /var/lib/docker/aufs\r\n Backing Filesystem: extfs\r\n Dirs: 201\r\n Dirperm1 Supported: true\r\nLogging Driver: json-file\r\nCgroup Driver: cgroupfs\r\nPlugins:\r\n Volume: local\r\n Network: overlay bridge host null\r\nSwarm: active\r\n NodeID: eq2uc7oz4ge5dx0ooc7k2wflz\r\n Is Manager: true\r\n ClusterID: bzgt4x9ylks43eu4q6km1o80z\r\n Managers: 1\r\n Nodes: 1\r\n Orchestration:\r\n  Task History Retention Limit: 10\r\n Raft:\r\n  Snapshot interval: 10000\r\n  Heartbeat tick: 1\r\n  Election tick: 3\r\n Dispatcher:\r\n  Heartbeat period: 5 seconds\r\n CA configuration:\r\n  Expiry duration: 3 months\r\n Node Address: 192.168.65.2\r\nRuntimes: runc\r\nDefault Runtime: runc\r\nSecurity Options: seccomp\r\nKernel Version: 4.4.15-moby\r\nOperating System: Alpine Linux v3.4\r\nOSType: linux\r\nArchitecture: x86_64\r\nCPUs: 4\r\nTotal Memory: 1.954 GiB\r\nName: moby\r\nID: K2ME:GK6I:GEAO:454Y:I6XE:M63Q:PVR2:4EPP:UY7U:S6JI:5OZT:FKN2\r\nDocker Root Dir: /var/lib/docker\r\nDebug Mode (client): false\r\nDebug Mode (server): true\r\n File Descriptors: 75\r\n Goroutines: 171\r\n System Time: 2016-08-02T16:37:32.670912274Z\r\n EventsListeners: 1\r\nNo Proxy: *.local, 169.254/16\r\nUsername: jhorwit2\r\nRegistry: https://index.docker.io/v1/\r\nInsecure Registries:\r\n 127.0.0.0/8\r\n```\r\n\r\n**Additional environment details (AWS, VirtualBox, physical, etc.):**\r\n\r\n\r\n\r\n**Steps to reproduce the issue:**\r\n1. `docker swarm init`\r\n2. `docker network create -d overlay backend`\r\n3. `docker service create --name nginx --network backend --publish 8088:80 nginx`\r\n4. `docker service update --publish-rm 8088 nginx`\r\n\r\n\r\n**Describe the results you received:**\r\n\r\n```\r\n$ docker service update --publish-rm 8088 test\r\ntest\r\n```\r\n\r\n**Describe the results you expected:**\r\n\r\nSince 8088 is the published port, not the target port that `--publish-rm` expects it should error out instead of _acting_ like it's working but not. \r\n\r\n```\r\n$ docker service update --publish-rm 8088 test\r\n<some error about port 8088 not being able to be removed>\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/docker/docker/issues/comments/240902789","html_url":"https://github.com/docker/docker/issues/25338#issuecomment-240902789","issue_url":"https://api.github.com/repos/docker/docker/issues/25338","id":240902789,"user":{"login":"yongtang","id":6932348,"avatar_url":"https://avatars.githubusercontent.com/u/6932348?v=3","gravatar_id":"","url":"https://api.github.com/users/yongtang","html_url":"https://github.com/yongtang","followers_url":"https://api.github.com/users/yongtang/followers","following_url":"https://api.github.com/users/yongtang/following{/other_user}","gists_url":"https://api.github.com/users/yongtang/gists{/gist_id}","starred_url":"https://api.github.com/users/yongtang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yongtang/subscriptions","organizations_url":"https://api.github.com/users/yongtang/orgs","repos_url":"https://api.github.com/users/yongtang/repos","events_url":"https://api.github.com/users/yongtang/events{/privacy}","received_events_url":"https://api.github.com/users/yongtang/received_events","type":"User","site_admin":false},"created_at":"2016-08-19T01:17:48Z","updated_at":"2016-08-19T01:17:48Z","body":"Thanks @dnephin! I didn't notice the equalPort before. It looks like equalPort may not cover the case where `port.Protocol` is `\"\"` yet `targetPort.Proto()` is `tcp`.\r\n\r\nI created a pull request #25860 to update the `equalPort`. It also adds the error checking for `--publish-rm` so that if the user provides an incorrect format (like `--publish-rm 80:80`) then at least they will be notified.\r\n\r\nPlease take a look and let me know if there are any issues or if there are better ways."}}
{"actor":{"display_login":"yongtang"}}