Forked from jhonnrodr/Unir Stack en Apache + Nodejs con puertos
Last active
August 29, 2015 14:14
-
-
Save bran921007/1abb0118b22db25f54d8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
DocumentRoot /var/www/linc/public | |
ErrorLog ${APACHE_LOG_DIR}/error.log | |
CustomLog ${APACHE_LOG_DIR}/access.log combined | |
ProxyRequests Off | |
<proxy *> | |
Order deny,allow | |
Allow from all | |
</proxy> | |
ProxyPreserveHost On | |
ProxyPass /node http://104.236.0.225:8001 | |
ProxyPassReverse /node http://104.236.0.225:8001 | |
</VirtualHost> | |
---------------------------------------------------------- | |
var app = require('express')(); | |
var server = require('http').Server(app); | |
var io = require('socket.io')(server); | |
var redis = require('redis'); | |
server.listen(8001); | |
app.get('/', function(req, res){ | |
res.send('Esta funcionando Node!'); | |
}); | |
console.log("Node Corriendo!"); | |
io.on('connection', function (socket) { | |
}); | |
-------------------------------------------- | |
<script src="{{ URL::asset('node/socket.io/socket.io.js') }}" type="text/javascript"></script> | |
var socket = io.connect('104.236.0.225:8001'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment