{"action":"opened","number":3,"pull_request":{"url":"https://api.github.com/repos/wwitzel3/juju/pulls/3","id":32372812,"html_url":"https://github.com/wwitzel3/juju/pull/3","diff_url":"https://github.com/wwitzel3/juju/pull/3.diff","patch_url":"https://github.com/wwitzel3/juju/pull/3.patch","issue_url":"https://api.github.com/repos/wwitzel3/juju/issues/3","number":3,"state":"open","locked":false,"title":"Adding command line parsing for endpoint files","user":{"login":"mbruzek","id":6385185,"avatar_url":"https://avatars.githubusercontent.com/u/6385185?v=3","gravatar_id":"","url":"https://api.github.com/users/mbruzek","html_url":"https://github.com/mbruzek","followers_url":"https://api.github.com/users/mbruzek/followers","following_url":"https://api.github.com/users/mbruzek/following{/other_user}","gists_url":"https://api.github.com/users/mbruzek/gists{/gist_id}","starred_url":"https://api.github.com/users/mbruzek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbruzek/subscriptions","organizations_url":"https://api.github.com/users/mbruzek/orgs","repos_url":"https://api.github.com/users/mbruzek/repos","events_url":"https://api.github.com/users/mbruzek/events{/privacy}","received_events_url":"https://api.github.com/users/mbruzek/received_events","type":"User","site_admin":false},"body":"The way the current code handles an endpoint file is it handles 1 definition in the file.  This fix changes the virtual services command-line parsing to accept the `--endpoints` or `--endpoints-file` flags.\r\n\r\nExample usage of the `--endpoints` flag:\r\n\r\n    juju deploy virtual:matt --endpoints='db:mysql={\"database\":\"juju\", \"user\": \"root\", \"password\": \"root\", \"private-address\": \"172.17.42.1\"}'\r\n\r\nExamples usage of the `--endpoints-file` flag:\r\n\r\n    juju deploy virtual:matt2 --endpoints-file=/tmp/matt.json\r\n    juju deploy virtual:matt3 --endpoints-file=/tmp/matt.yaml\r\n\r\nWhere `matt.json` is:\r\n```\r\n{\r\n  \"endpoints\":[\r\n    {\r\n      \"relation\":\"website\",\r\n      \"interface\":\"http\",\r\n      \"values\": {\r\n        \"hostname\":\"10.0.3.1\",\r\n        \"port\":\"6543\",\r\n        \"private-address\" :\"10.0.3.1\"\r\n      }\r\n    }\r\n  ]\r\n}\r\n```\r\nand `matt.yaml` is:\r\n```\r\nendpoints:\r\n- interface: http\r\n  relation: website\r\n  values:\r\n    hostname: 10.0.3.1\r\n    port: '6543'\r\n    private-address: 10.0.3.1\r\n```","created_at":"2015-03-31T22:31:17Z","updated_at":"2015-03-31T22:31:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/wwitzel3/juju/pulls/3/commits","review_comments_url":"https://api.github.com/repos/wwitzel3/juju/pulls/3/comments","review_comment_url":"https://api.github.com/repos/wwitzel3/juju/pulls/comments{/number}","comments_url":"https://api.github.com/repos/wwitzel3/juju/issues/3/comments","statuses_url":"https://api.github.com/repos/wwitzel3/juju/statuses/f9394704c2937996d471f7f6a7b1ff8bfa56a2c2","head":{"label":"mbruzek:cli-parse","ref":"cli-parse","sha":"f9394704c2937996d471f7f6a7b1ff8bfa56a2c2","user":{"login":"mbruzek","id":6385185,"avatar_url":"https://avatars.githubusercontent.com/u/6385185?v=3","gravatar_id":"","url":"https://api.github.com/users/mbruzek","html_url":"https://github.com/mbruzek","followers_url":"https://api.github.com/users/mbruzek/followers","following_url":"https://api.github.com/users/mbruzek/following{/other_user}","gists_url":"https://api.github.com/users/mbruzek/gists{/gist_id}","starred_url":"https://api.github.com/users/mbruzek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbruzek/subscriptions","organizations_url":"https://api.github.com/users/mbruzek/orgs","repos_url":"https://api.github.com/users/mbruzek/repos","events_url":"https://api.github.com/users/mbruzek/events{/privacy}","received_events_url":"https://api.github.com/users/mbruzek/received_events","type":"User","site_admin":false},"repo":{"id":32754576,"name":"juju","full_name":"mbruzek/juju","owner":{"login":"mbruzek","id":6385185,"avatar_url":"https://avatars.githubusercontent.com/u/6385185?v=3","gravatar_id":"","url":"https://api.github.com/users/mbruzek","html_url":"https://github.com/mbruzek","followers_url":"https://api.github.com/users/mbruzek/followers","following_url":"https://api.github.com/users/mbruzek/following{/other_user}","gists_url":"https://api.github.com/users/mbruzek/gists{/gist_id}","starred_url":"https://api.github.com/users/mbruzek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbruzek/subscriptions","organizations_url":"https://api.github.com/users/mbruzek/orgs","repos_url":"https://api.github.com/users/mbruzek/repos","events_url":"https://api.github.com/users/mbruzek/events{/privacy}","received_events_url":"https://api.github.com/users/mbruzek/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mbruzek/juju","description":"juju is devops distilled","fork":true,"url":"https://api.github.com/repos/mbruzek/juju","forks_url":"https://api.github.com/repos/mbruzek/juju/forks","keys_url":"https://api.github.com/repos/mbruzek/juju/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mbruzek/juju/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mbruzek/juju/teams","hooks_url":"https://api.github.com/repos/mbruzek/juju/hooks","issue_events_url":"https://api.github.com/repos/mbruzek/juju/issues/events{/number}","events_url":"https://api.github.com/repos/mbruzek/juju/events","assignees_url":"https://api.github.com/repos/mbruzek/juju/assignees{/user}","branches_url":"https://api.github.com/repos/mbruzek/juju/branches{/branch}","tags_url":"https://api.github.com/repos/mbruzek/juju/tags","blobs_url":"https://api.github.com/repos/mbruzek/juju/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mbruzek/juju/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mbruzek/juju/git/refs{/sha}","trees_url":"https://api.github.com/repos/mbruzek/juju/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mbruzek/juju/statuses/{sha}","languages_url":"https://api.github.com/repos/mbruzek/juju/languages","stargazers_url":"https://api.github.com/repos/mbruzek/juju/stargazers","contributors_url":"https://api.github.com/repos/mbruzek/juju/contributors","subscribers_url":"https://api.github.com/repos/mbruzek/juju/subscribers","subscription_url":"https://api.github.com/repos/mbruzek/juju/subscription","commits_url":"https://api.github.com/repos/mbruzek/juju/commits{/sha}","git_commits_url":"https://api.github.com/repos/mbruzek/juju/git/commits{/sha}","comments_url":"https://api.github.com/repos/mbruzek/juju/comments{/number}","issue_comment_url":"https://api.github.com/repos/mbruzek/juju/issues/comments{/number}","contents_url":"https://api.github.com/repos/mbruzek/juju/contents/{+path}","compare_url":"https://api.github.com/repos/mbruzek/juju/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mbruzek/juju/merges","archive_url":"https://api.github.com/repos/mbruzek/juju/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mbruzek/juju/downloads","issues_url":"https://api.github.com/repos/mbruzek/juju/issues{/number}","pulls_url":"https://api.github.com/repos/mbruzek/juju/pulls{/number}","milestones_url":"https://api.github.com/repos/mbruzek/juju/milestones{/number}","notifications_url":"https://api.github.com/repos/mbruzek/juju/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mbruzek/juju/labels{/name}","releases_url":"https://api.github.com/repos/mbruzek/juju/releases{/id}","created_at":"2015-03-23T19:39:01Z","updated_at":"2015-03-23T19:39:06Z","pushed_at":"2015-03-31T22:18:05Z","git_url":"git://github.com/mbruzek/juju.git","ssh_url":"git@github.com:mbruzek/juju.git","clone_url":"https://github.com/mbruzek/juju.git","svn_url":"https://github.com/mbruzek/juju","homepage":"juju.ubuntu.com","size":45468,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"wwitzel3:master","ref":"master","sha":"0752a4bc5dc1e838585ab489d6ab84270c1eccfa","user":{"login":"wwitzel3","id":27317,"avatar_url":"https://avatars.githubusercontent.com/u/27317?v=3","gravatar_id":"","url":"https://api.github.com/users/wwitzel3","html_url":"https://github.com/wwitzel3","followers_url":"https://api.github.com/users/wwitzel3/followers","following_url":"https://api.github.com/users/wwitzel3/following{/other_user}","gists_url":"https://api.github.com/users/wwitzel3/gists{/gist_id}","starred_url":"https://api.github.com/users/wwitzel3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wwitzel3/subscriptions","organizations_url":"https://api.github.com/users/wwitzel3/orgs","repos_url":"https://api.github.com/users/wwitzel3/repos","events_url":"https://api.github.com/users/wwitzel3/events{/privacy}","received_events_url":"https://api.github.com/users/wwitzel3/received_events","type":"User","site_admin":false},"repo":{"id":20449402,"name":"juju","full_name":"wwitzel3/juju","owner":{"login":"wwitzel3","id":27317,"avatar_url":"https://avatars.githubusercontent.com/u/27317?v=3","gravatar_id":"","url":"https://api.github.com/users/wwitzel3","html_url":"https://github.com/wwitzel3","followers_url":"https://api.github.com/users/wwitzel3/followers","following_url":"https://api.github.com/users/wwitzel3/following{/other_user}","gists_url":"https://api.github.com/users/wwitzel3/gists{/gist_id}","starred_url":"https://api.github.com/users/wwitzel3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wwitzel3/subscriptions","organizations_url":"https://api.github.com/users/wwitzel3/orgs","repos_url":"https://api.github.com/users/wwitzel3/repos","events_url":"https://api.github.com/users/wwitzel3/events{/privacy}","received_events_url":"https://api.github.com/users/wwitzel3/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/wwitzel3/juju","description":"juju is devops distilled","fork":true,"url":"https://api.github.com/repos/wwitzel3/juju","forks_url":"https://api.github.com/repos/wwitzel3/juju/forks","keys_url":"https://api.github.com/repos/wwitzel3/juju/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wwitzel3/juju/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wwitzel3/juju/teams","hooks_url":"https://api.github.com/repos/wwitzel3/juju/hooks","issue_events_url":"https://api.github.com/repos/wwitzel3/juju/issues/events{/number}","events_url":"https://api.github.com/repos/wwitzel3/juju/events","assignees_url":"https://api.github.com/repos/wwitzel3/juju/assignees{/user}","branches_url":"https://api.github.com/repos/wwitzel3/juju/branches{/branch}","tags_url":"https://api.github.com/repos/wwitzel3/juju/tags","blobs_url":"https://api.github.com/repos/wwitzel3/juju/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wwitzel3/juju/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wwitzel3/juju/git/refs{/sha}","trees_url":"https://api.github.com/repos/wwitzel3/juju/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wwitzel3/juju/statuses/{sha}","languages_url":"https://api.github.com/repos/wwitzel3/juju/languages","stargazers_url":"https://api.github.com/repos/wwitzel3/juju/stargazers","contributors_url":"https://api.github.com/repos/wwitzel3/juju/contributors","subscribers_url":"https://api.github.com/repos/wwitzel3/juju/subscribers","subscription_url":"https://api.github.com/repos/wwitzel3/juju/subscription","commits_url":"https://api.github.com/repos/wwitzel3/juju/commits{/sha}","git_commits_url":"https://api.github.com/repos/wwitzel3/juju/git/commits{/sha}","comments_url":"https://api.github.com/repos/wwitzel3/juju/comments{/number}","issue_comment_url":"https://api.github.com/repos/wwitzel3/juju/issues/comments{/number}","contents_url":"https://api.github.com/repos/wwitzel3/juju/contents/{+path}","compare_url":"https://api.github.com/repos/wwitzel3/juju/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wwitzel3/juju/merges","archive_url":"https://api.github.com/repos/wwitzel3/juju/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wwitzel3/juju/downloads","issues_url":"https://api.github.com/repos/wwitzel3/juju/issues{/number}","pulls_url":"https://api.github.com/repos/wwitzel3/juju/pulls{/number}","milestones_url":"https://api.github.com/repos/wwitzel3/juju/milestones{/number}","notifications_url":"https://api.github.com/repos/wwitzel3/juju/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wwitzel3/juju/labels{/name}","releases_url":"https://api.github.com/repos/wwitzel3/juju/releases{/id}","created_at":"2014-06-03T16:00:24Z","updated_at":"2015-03-23T18:07:16Z","pushed_at":"2015-03-27T20:19:19Z","git_url":"git://github.com/wwitzel3/juju.git","ssh_url":"git@github.com:wwitzel3/juju.git","clone_url":"https://github.com/wwitzel3/juju.git","svn_url":"https://github.com/wwitzel3/juju","homepage":null,"size":46459,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/wwitzel3/juju/pulls/3"},"html":{"href":"https://github.com/wwitzel3/juju/pull/3"},"issue":{"href":"https://api.github.com/repos/wwitzel3/juju/issues/3"},"comments":{"href":"https://api.github.com/repos/wwitzel3/juju/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/wwitzel3/juju/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/wwitzel3/juju/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/wwitzel3/juju/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/wwitzel3/juju/statuses/f9394704c2937996d471f7f6a7b1ff8bfa56a2c2"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":22,"additions":519,"deletions":23,"changed_files":19}}