#Launch an instance http://docs.aws.amazon.com/AmazonVPC/latest/GettingStartedGuide/GetStarted.html
#Setup EC2
chmod 400 key.pem
ssh -i key.pem ec2-user@YOUR_SERVER_IP
#Launch an instance http://docs.aws.amazon.com/AmazonVPC/latest/GettingStartedGuide/GetStarted.html
#Setup EC2
chmod 400 key.pem
ssh -i key.pem ec2-user@YOUR_SERVER_IP
| <!doctype html> | |
| <html lang='ja'> | |
| <head> | |
| <meta charset='utf-8' /> | |
| <title>socket.io client test</title> | |
| <script src="/json.js"></script> <!-- for ie --> | |
| <script src="/socket.io/socket.io.js"></script> | |
| <script src='http://www.google.com/jsapi'></script> | |
| <script> | |
| google.load('jquery', '1'); |
| module.exports = (function() { | |
| /* | |
| Recursive Dimensional Clustering | |
| http://lab.polygonal.de/articles/recursive-dimensional-clustering/ | |
| */ | |
| var RDC = function (collide) { | |
| this.collide = collide; | |
| }; | |
| // RDC.SUBDIVISION_THRESHOLD = 4; | |
| // RDC.CONTACT_THRESHOLD = 0.1; |
| var FB = require('fb'); | |
| FB.api('oauth/access_token', { | |
| client_id: process.env.FACEBOOK_APP_ID, | |
| client_secret: process.env.FACEBOOK_SECRET, | |
| grant_type: 'client_credentials' | |
| }, function(res) { | |
| if (!res || res.error) { | |
| console.log('error occurred when getting access token:', res && res.error); | |
| return; |