{"action":"created","comment":{"url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/comments/34531596","id":34531596,"diff_hunk":"@@ -0,0 +1,48 @@\n+/* @flow */\n+\n+import path from \"path\";\n+import express from \"express\";\n+import app from \"./app\";\n+import config from \"./config\";\n+import render from \"./server/render\";\n+\n+// Initialize express server\n+\n+var server = express();\n+\n+// On production, use the public directory for static files\n+// This directory is created by webpack at build time.\n+if (server.get(\"env\") === \"production\") {\n+    server.use(express.static(path.resolve(__dirname, \"../public\"), {\n+        maxAge: 365 * 24 * 60 * 60,\n+    }));\n+}\n+\n+// On development, serve the static files from the webpack dev server.\n+if (server.get(\"env\") === \"development\") {\n+    require(\"../webpack/server\");\n+}\n+\n+// Render the app server-side and send it as response\n+\n+server.use(render);\n+\n+// Generic server errors (e.g. not caught by components)\n+server.use((err, req, res, next) => {  // eslint-disable-line no-unused-vars\n+    console.log(\"Error on request %s %s\", req.method, req.url);\n+    console.log(err);\n+    console.log(err.stack);\n+    res.status(500).send(\"Something bad happened\");\n+});\n+\n+// Finally, start the express server\n+server.set(\"port\", process.env.PORT || 3000);","path":"src/server.js","position":39,"original_position":39,"commit_id":"833478698be26a42fc5e5627e77fc8bf28569a07","original_commit_id":"833478698be26a42fc5e5627e77fc8bf28569a07","user":{"login":"danni","id":129472,"avatar_url":"https://avatars.githubusercontent.com/u/129472?v=3","gravatar_id":"","url":"https://api.github.com/users/danni","html_url":"https://github.com/danni","followers_url":"https://api.github.com/users/danni/followers","following_url":"https://api.github.com/users/danni/following{/other_user}","gists_url":"https://api.github.com/users/danni/gists{/gist_id}","starred_url":"https://api.github.com/users/danni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danni/subscriptions","organizations_url":"https://api.github.com/users/danni/orgs","repos_url":"https://api.github.com/users/danni/repos","events_url":"https://api.github.com/users/danni/events{/privacy}","received_events_url":"https://api.github.com/users/danni/received_events","type":"User","site_admin":false},"body":"This is 8000 on IXA infra.","created_at":"2015-07-14T02:00:11Z","updated_at":"2015-07-14T02:00:11Z","html_url":"https://github.com/ask-izzy/ask-izzy/pull/7#discussion_r34531596","pull_request_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/comments/34531596"},"html":{"href":"https://github.com/ask-izzy/ask-izzy/pull/7#discussion_r34531596"},"pull_request":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7","id":39782764,"html_url":"https://github.com/ask-izzy/ask-izzy/pull/7","diff_url":"https://github.com/ask-izzy/ask-izzy/pull/7.diff","patch_url":"https://github.com/ask-izzy/ask-izzy/pull/7.patch","issue_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/7","number":7,"state":"open","locked":false,"title":"Isomorphic project setup, heavily inspired by","user":{"login":"DanielHeath","id":47430,"avatar_url":"https://avatars.githubusercontent.com/u/47430?v=3","gravatar_id":"","url":"https://api.github.com/users/DanielHeath","html_url":"https://github.com/DanielHeath","followers_url":"https://api.github.com/users/DanielHeath/followers","following_url":"https://api.github.com/users/DanielHeath/following{/other_user}","gists_url":"https://api.github.com/users/DanielHeath/gists{/gist_id}","starred_url":"https://api.github.com/users/DanielHeath/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DanielHeath/subscriptions","organizations_url":"https://api.github.com/users/DanielHeath/orgs","repos_url":"https://api.github.com/users/DanielHeath/repos","events_url":"https://api.github.com/users/DanielHeath/events{/privacy}","received_events_url":"https://api.github.com/users/DanielHeath/received_events","type":"User","site_admin":false},"body":"github.com/gpbl/isomorphic500","created_at":"2015-07-13T06:40:04Z","updated_at":"2015-07-14T02:00:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8673d0af65282069711b1c324bad6c1bd9cbed20","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7/commits","review_comments_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7/comments","review_comment_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/7/comments","statuses_url":"https://api.github.com/repos/ask-izzy/ask-izzy/statuses/833478698be26a42fc5e5627e77fc8bf28569a07","head":{"label":"ask-izzy:isomorphic_server","ref":"isomorphic_server","sha":"833478698be26a42fc5e5627e77fc8bf28569a07","user":{"login":"ask-izzy","id":13228149,"avatar_url":"https://avatars.githubusercontent.com/u/13228149?v=3","gravatar_id":"","url":"https://api.github.com/users/ask-izzy","html_url":"https://github.com/ask-izzy","followers_url":"https://api.github.com/users/ask-izzy/followers","following_url":"https://api.github.com/users/ask-izzy/following{/other_user}","gists_url":"https://api.github.com/users/ask-izzy/gists{/gist_id}","starred_url":"https://api.github.com/users/ask-izzy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ask-izzy/subscriptions","organizations_url":"https://api.github.com/users/ask-izzy/orgs","repos_url":"https://api.github.com/users/ask-izzy/repos","events_url":"https://api.github.com/users/ask-izzy/events{/privacy}","received_events_url":"https://api.github.com/users/ask-izzy/received_events","type":"Organization","site_admin":false},"repo":{"id":38803637,"name":"ask-izzy","full_name":"ask-izzy/ask-izzy","owner":{"login":"ask-izzy","id":13228149,"avatar_url":"https://avatars.githubusercontent.com/u/13228149?v=3","gravatar_id":"","url":"https://api.github.com/users/ask-izzy","html_url":"https://github.com/ask-izzy","followers_url":"https://api.github.com/users/ask-izzy/followers","following_url":"https://api.github.com/users/ask-izzy/following{/other_user}","gists_url":"https://api.github.com/users/ask-izzy/gists{/gist_id}","starred_url":"https://api.github.com/users/ask-izzy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ask-izzy/subscriptions","organizations_url":"https://api.github.com/users/ask-izzy/orgs","repos_url":"https://api.github.com/users/ask-izzy/repos","events_url":"https://api.github.com/users/ask-izzy/events{/privacy}","received_events_url":"https://api.github.com/users/ask-izzy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ask-izzy/ask-izzy","description":"","fork":false,"url":"https://api.github.com/repos/ask-izzy/ask-izzy","forks_url":"https://api.github.com/repos/ask-izzy/ask-izzy/forks","keys_url":"https://api.github.com/repos/ask-izzy/ask-izzy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ask-izzy/ask-izzy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ask-izzy/ask-izzy/teams","hooks_url":"https://api.github.com/repos/ask-izzy/ask-izzy/hooks","issue_events_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/events{/number}","events_url":"https://api.github.com/repos/ask-izzy/ask-izzy/events","assignees_url":"https://api.github.com/repos/ask-izzy/ask-izzy/assignees{/user}","branches_url":"https://api.github.com/repos/ask-izzy/ask-izzy/branches{/branch}","tags_url":"https://api.github.com/repos/ask-izzy/ask-izzy/tags","blobs_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/refs{/sha}","trees_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ask-izzy/ask-izzy/statuses/{sha}","languages_url":"https://api.github.com/repos/ask-izzy/ask-izzy/languages","stargazers_url":"https://api.github.com/repos/ask-izzy/ask-izzy/stargazers","contributors_url":"https://api.github.com/repos/ask-izzy/ask-izzy/contributors","subscribers_url":"https://api.github.com/repos/ask-izzy/ask-izzy/subscribers","subscription_url":"https://api.github.com/repos/ask-izzy/ask-izzy/subscription","commits_url":"https://api.github.com/repos/ask-izzy/ask-izzy/commits{/sha}","git_commits_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/commits{/sha}","comments_url":"https://api.github.com/repos/ask-izzy/ask-izzy/comments{/number}","issue_comment_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/comments{/number}","contents_url":"https://api.github.com/repos/ask-izzy/ask-izzy/contents/{+path}","compare_url":"https://api.github.com/repos/ask-izzy/ask-izzy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ask-izzy/ask-izzy/merges","archive_url":"https://api.github.com/repos/ask-izzy/ask-izzy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ask-izzy/ask-izzy/downloads","issues_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues{/number}","pulls_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls{/number}","milestones_url":"https://api.github.com/repos/ask-izzy/ask-izzy/milestones{/number}","notifications_url":"https://api.github.com/repos/ask-izzy/ask-izzy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ask-izzy/ask-izzy/labels{/name}","releases_url":"https://api.github.com/repos/ask-izzy/ask-izzy/releases{/id}","created_at":"2015-07-09T07:03:09Z","updated_at":"2015-07-13T06:02:16Z","pushed_at":"2015-07-14T01:54:26Z","git_url":"git://github.com/ask-izzy/ask-izzy.git","ssh_url":"git@github.com:ask-izzy/ask-izzy.git","clone_url":"https://github.com/ask-izzy/ask-izzy.git","svn_url":"https://github.com/ask-izzy/ask-izzy","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"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"}},"base":{"label":"ask-izzy:master","ref":"master","sha":"7c35d588a5c3cb690c495a146b82c58ea0f00891","user":{"login":"ask-izzy","id":13228149,"avatar_url":"https://avatars.githubusercontent.com/u/13228149?v=3","gravatar_id":"","url":"https://api.github.com/users/ask-izzy","html_url":"https://github.com/ask-izzy","followers_url":"https://api.github.com/users/ask-izzy/followers","following_url":"https://api.github.com/users/ask-izzy/following{/other_user}","gists_url":"https://api.github.com/users/ask-izzy/gists{/gist_id}","starred_url":"https://api.github.com/users/ask-izzy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ask-izzy/subscriptions","organizations_url":"https://api.github.com/users/ask-izzy/orgs","repos_url":"https://api.github.com/users/ask-izzy/repos","events_url":"https://api.github.com/users/ask-izzy/events{/privacy}","received_events_url":"https://api.github.com/users/ask-izzy/received_events","type":"Organization","site_admin":false},"repo":{"id":38803637,"name":"ask-izzy","full_name":"ask-izzy/ask-izzy","owner":{"login":"ask-izzy","id":13228149,"avatar_url":"https://avatars.githubusercontent.com/u/13228149?v=3","gravatar_id":"","url":"https://api.github.com/users/ask-izzy","html_url":"https://github.com/ask-izzy","followers_url":"https://api.github.com/users/ask-izzy/followers","following_url":"https://api.github.com/users/ask-izzy/following{/other_user}","gists_url":"https://api.github.com/users/ask-izzy/gists{/gist_id}","starred_url":"https://api.github.com/users/ask-izzy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ask-izzy/subscriptions","organizations_url":"https://api.github.com/users/ask-izzy/orgs","repos_url":"https://api.github.com/users/ask-izzy/repos","events_url":"https://api.github.com/users/ask-izzy/events{/privacy}","received_events_url":"https://api.github.com/users/ask-izzy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ask-izzy/ask-izzy","description":"","fork":false,"url":"https://api.github.com/repos/ask-izzy/ask-izzy","forks_url":"https://api.github.com/repos/ask-izzy/ask-izzy/forks","keys_url":"https://api.github.com/repos/ask-izzy/ask-izzy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ask-izzy/ask-izzy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ask-izzy/ask-izzy/teams","hooks_url":"https://api.github.com/repos/ask-izzy/ask-izzy/hooks","issue_events_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/events{/number}","events_url":"https://api.github.com/repos/ask-izzy/ask-izzy/events","assignees_url":"https://api.github.com/repos/ask-izzy/ask-izzy/assignees{/user}","branches_url":"https://api.github.com/repos/ask-izzy/ask-izzy/branches{/branch}","tags_url":"https://api.github.com/repos/ask-izzy/ask-izzy/tags","blobs_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/refs{/sha}","trees_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ask-izzy/ask-izzy/statuses/{sha}","languages_url":"https://api.github.com/repos/ask-izzy/ask-izzy/languages","stargazers_url":"https://api.github.com/repos/ask-izzy/ask-izzy/stargazers","contributors_url":"https://api.github.com/repos/ask-izzy/ask-izzy/contributors","subscribers_url":"https://api.github.com/repos/ask-izzy/ask-izzy/subscribers","subscription_url":"https://api.github.com/repos/ask-izzy/ask-izzy/subscription","commits_url":"https://api.github.com/repos/ask-izzy/ask-izzy/commits{/sha}","git_commits_url":"https://api.github.com/repos/ask-izzy/ask-izzy/git/commits{/sha}","comments_url":"https://api.github.com/repos/ask-izzy/ask-izzy/comments{/number}","issue_comment_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/comments{/number}","contents_url":"https://api.github.com/repos/ask-izzy/ask-izzy/contents/{+path}","compare_url":"https://api.github.com/repos/ask-izzy/ask-izzy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ask-izzy/ask-izzy/merges","archive_url":"https://api.github.com/repos/ask-izzy/ask-izzy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ask-izzy/ask-izzy/downloads","issues_url":"https://api.github.com/repos/ask-izzy/ask-izzy/issues{/number}","pulls_url":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls{/number}","milestones_url":"https://api.github.com/repos/ask-izzy/ask-izzy/milestones{/number}","notifications_url":"https://api.github.com/repos/ask-izzy/ask-izzy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ask-izzy/ask-izzy/labels{/name}","releases_url":"https://api.github.com/repos/ask-izzy/ask-izzy/releases{/id}","created_at":"2015-07-09T07:03:09Z","updated_at":"2015-07-13T06:02:16Z","pushed_at":"2015-07-14T01:54:26Z","git_url":"git://github.com/ask-izzy/ask-izzy.git","ssh_url":"git@github.com:ask-izzy/ask-izzy.git","clone_url":"https://github.com/ask-izzy/ask-izzy.git","svn_url":"https://github.com/ask-izzy/ask-izzy","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"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/ask-izzy/ask-izzy/pulls/7"},"html":{"href":"https://github.com/ask-izzy/ask-izzy/pull/7"},"issue":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/7"},"comments":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/ask-izzy/ask-izzy/statuses/833478698be26a42fc5e5627e77fc8bf28569a07"}}}}