{"action":"reopened","number":1618,"pull_request":{"url":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618","id":222530564,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIyNTMwNTY0","html_url":"https://github.com/aws/amazon-ecs-agent/pull/1618","diff_url":"https://github.com/aws/amazon-ecs-agent/pull/1618.diff","patch_url":"https://github.com/aws/amazon-ecs-agent/pull/1618.patch","issue_url":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/1618","number":1618,"state":"open","locked":false,"title":"ECS Agent tagging support","user":{"login":"haikuoliu","id":22357563,"node_id":"MDQ6VXNlcjIyMzU3NTYz","avatar_url":"https://avatars1.githubusercontent.com/u/22357563?v=4","gravatar_id":"","url":"https://api.github.com/users/haikuoliu","html_url":"https://github.com/haikuoliu","followers_url":"https://api.github.com/users/haikuoliu/followers","following_url":"https://api.github.com/users/haikuoliu/following{/other_user}","gists_url":"https://api.github.com/users/haikuoliu/gists{/gist_id}","starred_url":"https://api.github.com/users/haikuoliu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haikuoliu/subscriptions","organizations_url":"https://api.github.com/users/haikuoliu/orgs","repos_url":"https://api.github.com/users/haikuoliu/repos","events_url":"https://api.github.com/users/haikuoliu/events{/privacy}","received_events_url":"https://api.github.com/users/haikuoliu/received_events","type":"User","site_admin":false},"body":"<!--\r\nPlease make sure you've read and understood our contributing guidelines;\r\nhttps://github.com/aws/amazon-ecs-agent/blob/master/CONTRIBUTING.md\r\n\r\nPlease provide the following information:\r\n-->\r\n\r\n### Summary\r\n<!-- What does this pull request do? -->\r\nECS local tags support\r\n\r\n### Implementation details\r\n<!-- How are the changes implemented? -->\r\n1. Introduce `ECS_CONTAINER_INSTANCE_TAGS` env var to allow customer to configure tags on the instance.\r\n2. Introduce `ECS_CONTAINER_INSTANCE_PROPAGATE_TAGS` to get the tags of the ec2 instance that Agent is running on using DescribeTags API. We can specify either `none` or `ec2_instance` for this env var, the reason that we don't use a boolean is because we may introduce other ways to propagate the tags (like ask backend to propagate tags instead of doing it on Agent side).\r\n3. ECS model changes for tags, introduce a new API `ListTagsForResourceInput` for testing purpose.\r\n4. ECS client API changes to allow tags passed from RCI call.\r\n5. Introduce EC2 client API, `DescribeECSTagsForInstance` is used for RCI call, and `CreateTags` for func test.\r\n6. Add `InstanceID` API to EC2 metadata client.\r\n6. Functional test and manual test against Gamma endpoint.\r\n7. Vendor packages update.\r\n8. Joel reviewed my README.\r\n\r\n\r\nTODO:\r\nMake func test pass once the `ListTagsForResource` API is in prod.\r\n\r\n### Testing\r\n<!-- How was this tested? -->\r\n<!--\r\nNote for external contributors:\r\n`make test` and `make run-integ-tests` can run in a Linux development\r\nenvironment like your laptop.  `go test -timeout=25s ./agent/...` and\r\n`.\\scripts\\run-integ.tests.ps1` can run in a Windows development environment\r\nlike your laptop.  Please ensure unit and integration tests pass (on at least\r\none platform) before opening the pull request.  `make run-functional-tests` and\r\n`.\\scripts\\run-functional-tests.ps1` must be run on an EC2 instance with an\r\ninstance profile allowing it access to AWS resources.  Running\r\n`make run-functional-tests` and `.\\scripts\\run-functional-tests.ps1` may incur\r\ncharges to your AWS account; if you're unable or unwilling to run these tests\r\nin your own account, we can run the tests and provide test results.\r\n-->\r\n- [x] Builds on Linux (`make release`)\r\n- [x] Builds on Windows (`go build -out amazon-ecs-agent.exe ./agent`)\r\n- [x] Unit tests on Linux (`make test`) pass\r\n- [x] Unit tests on Windows (`go test -timeout=25s ./agent/...`) pass\r\n- [x] Integration tests on Linux (`make run-integ-tests`) pass\r\n- [ ] Integration tests on Windows (`.\\scripts\\run-integ-tests.ps1`) pass\r\n- [ ] Functional tests on Linux (`make run-functional-tests`) pass\r\n- [ ] Functional tests on Windows (`.\\scripts\\run-functional-tests.ps1`) pass\r\n\r\n### Description for the changelog\r\n<!--\r\nWrite a short (one line) summary that describes the changes in this\r\npull request for inclusion in the changelog.\r\nYou can see our changelog entry style here:\r\nhttps://github.com/aws/amazon-ecs-agent/commit/c9aefebc2b3007f09468f651f6308136bd7b384f\r\n-->\r\n\r\n### Licensing\r\n\r\nBy submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.\r\n","created_at":"2018-10-12T17:08:49Z","updated_at":"2018-10-25T18:41:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4f0e1059508c61d2a6462c4c8eed4c2b8053245a","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":1034649096,"node_id":"MDU6TGFiZWwxMDM0NjQ5MDk2","url":"https://api.github.com/repos/aws/amazon-ecs-agent/labels/bot/test","name":"bot/test","color":"41ccd8","default":false}],"milestone":{"url":"https://api.github.com/repos/aws/amazon-ecs-agent/milestones/34","html_url":"https://github.com/aws/amazon-ecs-agent/milestone/34","labels_url":"https://api.github.com/repos/aws/amazon-ecs-agent/milestones/34/labels","id":3712960,"node_id":"MDk6TWlsZXN0b25lMzcxMjk2MA==","number":34,"title":"1.22.0","description":"","creator":{"login":"haikuoliu","id":22357563,"node_id":"MDQ6VXNlcjIyMzU3NTYz","avatar_url":"https://avatars1.githubusercontent.com/u/22357563?v=4","gravatar_id":"","url":"https://api.github.com/users/haikuoliu","html_url":"https://github.com/haikuoliu","followers_url":"https://api.github.com/users/haikuoliu/followers","following_url":"https://api.github.com/users/haikuoliu/following{/other_user}","gists_url":"https://api.github.com/users/haikuoliu/gists{/gist_id}","starred_url":"https://api.github.com/users/haikuoliu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haikuoliu/subscriptions","organizations_url":"https://api.github.com/users/haikuoliu/orgs","repos_url":"https://api.github.com/users/haikuoliu/repos","events_url":"https://api.github.com/users/haikuoliu/events{/privacy}","received_events_url":"https://api.github.com/users/haikuoliu/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":11,"state":"open","created_at":"2018-10-04T17:58:16Z","updated_at":"2018-10-25T18:41:11Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618/commits","review_comments_url":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618/comments","review_comment_url":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/1618/comments","statuses_url":"https://api.github.com/repos/aws/amazon-ecs-agent/statuses/8f7e122c1b18329cb8161c63da125b512d188f35","head":{"label":"haikuoliu:tags","ref":"tags","sha":"8f7e122c1b18329cb8161c63da125b512d188f35","user":{"login":"haikuoliu","id":22357563,"node_id":"MDQ6VXNlcjIyMzU3NTYz","avatar_url":"https://avatars1.githubusercontent.com/u/22357563?v=4","gravatar_id":"","url":"https://api.github.com/users/haikuoliu","html_url":"https://github.com/haikuoliu","followers_url":"https://api.github.com/users/haikuoliu/followers","following_url":"https://api.github.com/users/haikuoliu/following{/other_user}","gists_url":"https://api.github.com/users/haikuoliu/gists{/gist_id}","starred_url":"https://api.github.com/users/haikuoliu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haikuoliu/subscriptions","organizations_url":"https://api.github.com/users/haikuoliu/orgs","repos_url":"https://api.github.com/users/haikuoliu/repos","events_url":"https://api.github.com/users/haikuoliu/events{/privacy}","received_events_url":"https://api.github.com/users/haikuoliu/received_events","type":"User","site_admin":false},"repo":{"id":123984338,"node_id":"MDEwOlJlcG9zaXRvcnkxMjM5ODQzMzg=","name":"amazon-ecs-agent","full_name":"haikuoliu/amazon-ecs-agent","private":false,"owner":{"login":"haikuoliu","id":22357563,"node_id":"MDQ6VXNlcjIyMzU3NTYz","avatar_url":"https://avatars1.githubusercontent.com/u/22357563?v=4","gravatar_id":"","url":"https://api.github.com/users/haikuoliu","html_url":"https://github.com/haikuoliu","followers_url":"https://api.github.com/users/haikuoliu/followers","following_url":"https://api.github.com/users/haikuoliu/following{/other_user}","gists_url":"https://api.github.com/users/haikuoliu/gists{/gist_id}","starred_url":"https://api.github.com/users/haikuoliu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haikuoliu/subscriptions","organizations_url":"https://api.github.com/users/haikuoliu/orgs","repos_url":"https://api.github.com/users/haikuoliu/repos","events_url":"https://api.github.com/users/haikuoliu/events{/privacy}","received_events_url":"https://api.github.com/users/haikuoliu/received_events","type":"User","site_admin":false},"html_url":"https://github.com/haikuoliu/amazon-ecs-agent","description":"Amazon Elastic Container Service Agent","fork":true,"url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent","forks_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/forks","keys_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/teams","hooks_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/hooks","issue_events_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/issues/events{/number}","events_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/events","assignees_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/assignees{/user}","branches_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/branches{/branch}","tags_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/tags","blobs_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/git/refs{/sha}","trees_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/statuses/{sha}","languages_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/languages","stargazers_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/stargazers","contributors_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/contributors","subscribers_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/subscribers","subscription_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/subscription","commits_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/commits{/sha}","git_commits_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/git/commits{/sha}","comments_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/comments{/number}","issue_comment_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/issues/comments{/number}","contents_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/contents/{+path}","compare_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/merges","archive_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/downloads","issues_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/issues{/number}","pulls_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/pulls{/number}","milestones_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/milestones{/number}","notifications_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/labels{/name}","releases_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/releases{/id}","deployments_url":"https://api.github.com/repos/haikuoliu/amazon-ecs-agent/deployments","created_at":"2018-03-05T22:00:41Z","updated_at":"2018-08-02T07:22:51Z","pushed_at":"2018-10-25T18:40:44Z","git_url":"git://github.com/haikuoliu/amazon-ecs-agent.git","ssh_url":"git@github.com:haikuoliu/amazon-ecs-agent.git","clone_url":"https://github.com/haikuoliu/amazon-ecs-agent.git","svn_url":"https://github.com/haikuoliu/amazon-ecs-agent","homepage":"http://aws.amazon.com/ecs/","size":41540,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"aws:dev","ref":"dev","sha":"0bdac274177303e59cb77de6a972de1475bff0af","user":{"login":"aws","id":2232217,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMzIyMTc=","avatar_url":"https://avatars3.githubusercontent.com/u/2232217?v=4","gravatar_id":"","url":"https://api.github.com/users/aws","html_url":"https://github.com/aws","followers_url":"https://api.github.com/users/aws/followers","following_url":"https://api.github.com/users/aws/following{/other_user}","gists_url":"https://api.github.com/users/aws/gists{/gist_id}","starred_url":"https://api.github.com/users/aws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aws/subscriptions","organizations_url":"https://api.github.com/users/aws/orgs","repos_url":"https://api.github.com/users/aws/repos","events_url":"https://api.github.com/users/aws/events{/privacy}","received_events_url":"https://api.github.com/users/aws/received_events","type":"Organization","site_admin":false},"repo":{"id":27551774,"node_id":"MDEwOlJlcG9zaXRvcnkyNzU1MTc3NA==","name":"amazon-ecs-agent","full_name":"aws/amazon-ecs-agent","private":false,"owner":{"login":"aws","id":2232217,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMzIyMTc=","avatar_url":"https://avatars3.githubusercontent.com/u/2232217?v=4","gravatar_id":"","url":"https://api.github.com/users/aws","html_url":"https://github.com/aws","followers_url":"https://api.github.com/users/aws/followers","following_url":"https://api.github.com/users/aws/following{/other_user}","gists_url":"https://api.github.com/users/aws/gists{/gist_id}","starred_url":"https://api.github.com/users/aws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aws/subscriptions","organizations_url":"https://api.github.com/users/aws/orgs","repos_url":"https://api.github.com/users/aws/repos","events_url":"https://api.github.com/users/aws/events{/privacy}","received_events_url":"https://api.github.com/users/aws/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/aws/amazon-ecs-agent","description":"Amazon Elastic Container Service Agent","fork":false,"url":"https://api.github.com/repos/aws/amazon-ecs-agent","forks_url":"https://api.github.com/repos/aws/amazon-ecs-agent/forks","keys_url":"https://api.github.com/repos/aws/amazon-ecs-agent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aws/amazon-ecs-agent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aws/amazon-ecs-agent/teams","hooks_url":"https://api.github.com/repos/aws/amazon-ecs-agent/hooks","issue_events_url":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/events{/number}","events_url":"https://api.github.com/repos/aws/amazon-ecs-agent/events","assignees_url":"https://api.github.com/repos/aws/amazon-ecs-agent/assignees{/user}","branches_url":"https://api.github.com/repos/aws/amazon-ecs-agent/branches{/branch}","tags_url":"https://api.github.com/repos/aws/amazon-ecs-agent/tags","blobs_url":"https://api.github.com/repos/aws/amazon-ecs-agent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aws/amazon-ecs-agent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aws/amazon-ecs-agent/git/refs{/sha}","trees_url":"https://api.github.com/repos/aws/amazon-ecs-agent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aws/amazon-ecs-agent/statuses/{sha}","languages_url":"https://api.github.com/repos/aws/amazon-ecs-agent/languages","stargazers_url":"https://api.github.com/repos/aws/amazon-ecs-agent/stargazers","contributors_url":"https://api.github.com/repos/aws/amazon-ecs-agent/contributors","subscribers_url":"https://api.github.com/repos/aws/amazon-ecs-agent/subscribers","subscription_url":"https://api.github.com/repos/aws/amazon-ecs-agent/subscription","commits_url":"https://api.github.com/repos/aws/amazon-ecs-agent/commits{/sha}","git_commits_url":"https://api.github.com/repos/aws/amazon-ecs-agent/git/commits{/sha}","comments_url":"https://api.github.com/repos/aws/amazon-ecs-agent/comments{/number}","issue_comment_url":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/comments{/number}","contents_url":"https://api.github.com/repos/aws/amazon-ecs-agent/contents/{+path}","compare_url":"https://api.github.com/repos/aws/amazon-ecs-agent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aws/amazon-ecs-agent/merges","archive_url":"https://api.github.com/repos/aws/amazon-ecs-agent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aws/amazon-ecs-agent/downloads","issues_url":"https://api.github.com/repos/aws/amazon-ecs-agent/issues{/number}","pulls_url":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls{/number}","milestones_url":"https://api.github.com/repos/aws/amazon-ecs-agent/milestones{/number}","notifications_url":"https://api.github.com/repos/aws/amazon-ecs-agent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aws/amazon-ecs-agent/labels{/name}","releases_url":"https://api.github.com/repos/aws/amazon-ecs-agent/releases{/id}","deployments_url":"https://api.github.com/repos/aws/amazon-ecs-agent/deployments","created_at":"2014-12-04T17:31:49Z","updated_at":"2018-10-25T17:10:22Z","pushed_at":"2018-10-25T18:40:34Z","git_url":"git://github.com/aws/amazon-ecs-agent.git","ssh_url":"git@github.com:aws/amazon-ecs-agent.git","clone_url":"https://github.com/aws/amazon-ecs-agent.git","svn_url":"https://github.com/aws/amazon-ecs-agent","homepage":"http://aws.amazon.com/ecs/","size":31845,"stargazers_count":1352,"watchers_count":1352,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":364,"mirror_url":null,"archived":false,"open_issues_count":107,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":364,"open_issues":107,"watchers":1352,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618"},"html":{"href":"https://github.com/aws/amazon-ecs-agent/pull/1618"},"issue":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/1618"},"comments":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/issues/1618/comments"},"review_comments":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618/comments"},"review_comment":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/pulls/1618/commits"},"statuses":{"href":"https://api.github.com/repos/aws/amazon-ecs-agent/statuses/8f7e122c1b18329cb8161c63da125b512d188f35"}},"author_association":"CONTRIBUTOR","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":3,"review_comments":31,"maintainer_can_modify":true,"commits":2,"additions":75208,"deletions":140,"changed_files":35}}
{"actor":{"display_login":"haikuoliu"}}