
var config = {
  server_port: 5000,
  server_opts: {}
};

var server = require('http').Server();
var serverio = require('socket.io').listen(server, config.server_opts);
server.listen(config.server_port);

var players = [];

var data = require('../data/apples.json');
var red = data.red,
  green = data.green;

serverio.of('/game').on('connection', function(socket) {
  // TODO: add socket

  socket.on('disconnect', function() {
    // TODO: remove socket
  });

  socket.on('authme', function() {

  });
});


var config = {
  server_port: 5000,
  server_opts: {}
};

var server = require('http').Server();
var serverio = require('socket.io').listen(server, config.server_opts);
server.listen(config.server_port);

var players = [];

var red_cards = require('../data/red.json'),
  green_cards = require('../data/green.json');

serverio.of('/game').on('connection', function(socket) {
  // TODO: add socket

  socket.on('disconnect', function() {
    // TODO: remove socket
  });

  socket.on('authme', function() {

  });
});

--- 
+++ 
@@ -10,8 +10,9 @@
 
 var players = [];
 
-var red_cards = require('../data/red.json'),
-  green_cards = require('../data/green.json');
+var data = require('../data/apples.json');
+var red = data.red,
+  green = data.green;
 
 serverio.of('/game').on('connection', function(socket) {
   // TODO: add socket
Use json file in reading
