{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/comments/74077651","id":74077651,"diff_hunk":"@@ -1,22 +1,19 @@\n-# ubuntu 16.04 xenial image\n-FROM ubuntu\n+# use base python\n+FROM python:2.7\n \n-# apt update it\n-RUN apt-get update\n-# get essentials\n-RUN apt-get install -y tar git curl wget dialog net-tools build-essential python python-dev python-distribute python-pip\n+# create app directory\n+RUN mkdir -p /app/\n+WORKDIR /app/\n \n-# add project directory\n-ADD . /telemetry-schema-service/\n+# install requirements\n+COPY requirements.txt /app/\n+RUN pip install --no-cache-dir --requirement requirements.txt\n \n-# pip install requirements.txt\n-RUN pip install -r /telemetry-schema-service/requirements.txt\n-\n-# exposing 8080 for flask app\n+# expose 8080 for flask app\n EXPOSE 8080\n \n-# workdir\n-WORKDIR /telemetry-schema-service/app\n+# copy application\n+COPY . /app/","path":"Dockerfile","position":30,"original_position":30,"commit_id":"fdaa2daecde3a22cec8b961806ba580792ca88ef","original_commit_id":"fdaa2daecde3a22cec8b961806ba580792ca88ef","user":{"login":"robotblake","id":131385,"avatar_url":"https://avatars.githubusercontent.com/u/131385?v=3","gravatar_id":"","url":"https://api.github.com/users/robotblake","html_url":"https://github.com/robotblake","followers_url":"https://api.github.com/users/robotblake/followers","following_url":"https://api.github.com/users/robotblake/following{/other_user}","gists_url":"https://api.github.com/users/robotblake/gists{/gist_id}","starred_url":"https://api.github.com/users/robotblake/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robotblake/subscriptions","organizations_url":"https://api.github.com/users/robotblake/orgs","repos_url":"https://api.github.com/users/robotblake/repos","events_url":"https://api.github.com/users/robotblake/events{/privacy}","received_events_url":"https://api.github.com/users/robotblake/received_events","type":"User","site_admin":false},"body":"To take advantage of docker layer caching, this way if the requirements.txt doesn't change it doesn't need to re-download all of those packages.\r\n\r\nhttps://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/#/add-or-copy","created_at":"2016-08-09T15:09:16Z","updated_at":"2016-08-09T15:09:16Z","html_url":"https://github.com/mozilla/telemetry-schema-service/pull/7#discussion_r74077651","pull_request_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/comments/74077651"},"html":{"href":"https://github.com/mozilla/telemetry-schema-service/pull/7#discussion_r74077651"},"pull_request":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7","id":80503833,"html_url":"https://github.com/mozilla/telemetry-schema-service/pull/7","diff_url":"https://github.com/mozilla/telemetry-schema-service/pull/7.diff","patch_url":"https://github.com/mozilla/telemetry-schema-service/pull/7.patch","issue_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/7","number":7,"state":"open","locked":false,"title":"Various changes to Dockerfile","user":{"login":"robotblake","id":131385,"avatar_url":"https://avatars.githubusercontent.com/u/131385?v=3","gravatar_id":"","url":"https://api.github.com/users/robotblake","html_url":"https://github.com/robotblake","followers_url":"https://api.github.com/users/robotblake/followers","following_url":"https://api.github.com/users/robotblake/following{/other_user}","gists_url":"https://api.github.com/users/robotblake/gists{/gist_id}","starred_url":"https://api.github.com/users/robotblake/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robotblake/subscriptions","organizations_url":"https://api.github.com/users/robotblake/orgs","repos_url":"https://api.github.com/users/robotblake/repos","events_url":"https://api.github.com/users/robotblake/events{/privacy}","received_events_url":"https://api.github.com/users/robotblake/received_events","type":"User","site_admin":false},"body":"* Use the \"python:2.7\" base image\r\n* Put application in /app as per \"Dockerflow\"\r\n* Add script that uses $PORT and $WORKERS when starting gunicorn\r\n* Re-order steps to take advantage of caching","created_at":"2016-08-08T19:04:18Z","updated_at":"2016-08-09T15:09:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4678c7e058e9c29868239866adcbb5fee670f93b","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7/commits","review_comments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7/comments","review_comment_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/7/comments","statuses_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/statuses/fdaa2daecde3a22cec8b961806ba580792ca88ef","head":{"label":"mozilla:cleaning","ref":"cleaning","sha":"fdaa2daecde3a22cec8b961806ba580792ca88ef","user":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":59769092,"name":"telemetry-schema-service","full_name":"mozilla/telemetry-schema-service","owner":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/telemetry-schema-service","description":"Service API to retrieve telemetry schemas and validate them against incoming json.","fork":false,"url":"https://api.github.com/repos/mozilla/telemetry-schema-service","forks_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/forks","keys_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/teams","hooks_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/hooks","issue_events_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/events","assignees_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/tags","blobs_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/languages","stargazers_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/stargazers","contributors_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/contributors","subscribers_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/subscribers","subscription_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/subscription","commits_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/merges","archive_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/downloads","issues_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/releases{/id}","deployments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/deployments","created_at":"2016-05-26T17:16:18Z","updated_at":"2016-08-03T19:53:55Z","pushed_at":"2016-08-08T19:04:23Z","git_url":"git://github.com/mozilla/telemetry-schema-service.git","ssh_url":"git@github.com:mozilla/telemetry-schema-service.git","clone_url":"https://github.com/mozilla/telemetry-schema-service.git","svn_url":"https://github.com/mozilla/telemetry-schema-service","homepage":"","size":90,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"mozilla:master","ref":"master","sha":"6405ba708c2ce1c4716923e628d0526a7a162273","user":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":59769092,"name":"telemetry-schema-service","full_name":"mozilla/telemetry-schema-service","owner":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/telemetry-schema-service","description":"Service API to retrieve telemetry schemas and validate them against incoming json.","fork":false,"url":"https://api.github.com/repos/mozilla/telemetry-schema-service","forks_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/forks","keys_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/teams","hooks_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/hooks","issue_events_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/events","assignees_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/tags","blobs_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/languages","stargazers_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/stargazers","contributors_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/contributors","subscribers_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/subscribers","subscription_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/subscription","commits_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/merges","archive_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/downloads","issues_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/releases{/id}","deployments_url":"https://api.github.com/repos/mozilla/telemetry-schema-service/deployments","created_at":"2016-05-26T17:16:18Z","updated_at":"2016-08-03T19:53:55Z","pushed_at":"2016-08-08T19:04:23Z","git_url":"git://github.com/mozilla/telemetry-schema-service.git","ssh_url":"git@github.com:mozilla/telemetry-schema-service.git","clone_url":"https://github.com/mozilla/telemetry-schema-service.git","svn_url":"https://github.com/mozilla/telemetry-schema-service","homepage":"","size":90,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7"},"html":{"href":"https://github.com/mozilla/telemetry-schema-service/pull/7"},"issue":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/7"},"comments":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla/telemetry-schema-service/statuses/fdaa2daecde3a22cec8b961806ba580792ca88ef"}}}}
{"actor":{"display_login":"robotblake"}}