Created
January 14, 2013 18:30
-
-
Save gabamnml/4532176 to your computer and use it in GitHub Desktop.
socket.io config for production
This file contains 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
io.configure('production', function(){ | |
console.log("Running Socket.io in production mode"); | |
io.enable('browser client minification'); // send minified client | |
io.enable('browser client etag'); // apply etag caching logic based on version number | |
io.enable('browser client gzip'); // gzip the file | |
io.set('log level', 1); // reduce logging | |
io.set('transports', [ // enable all transports (optional if you want flashsocket) | |
'websocket' | |
, 'flashsocket' | |
, 'htmlfile' | |
, 'xhr-polling' | |
, 'jsonp-polling' | |
]); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment