[CORD-2742] Remove elements from the service graph

Change-Id: Ibcb9fac4428f0b168ff66fab3219b8357e732dc5
diff --git a/conf/browsersync.conf.js b/conf/browsersync.conf.js
index ff3bb4f..23dee02 100644
--- a/conf/browsersync.conf.js
+++ b/conf/browsersync.conf.js
@@ -18,6 +18,7 @@
 
 const conf = require('./gulp.conf');
 const proxy = require('./proxy').proxy;
+const wsProxy = require('./proxy').wsProxy;
 
 module.exports = function () {
   return {
@@ -29,11 +30,15 @@
       middleware: function(req, res, next) {
         if (
           req.url.indexOf('xosapi') !== -1
-          || req.url.indexOf('socket.io') !== -1
           || req.url.indexOf('extensions') !== -1
         ) {
           proxy.web(req, res);
         }
+        else if (
+          req.url.indexOf('socket.io') !== -1
+        ) {
+          wsProxy.web(req, res);
+        }
         else {
           next();
         }
diff --git a/conf/proxy.js b/conf/proxy.js
index ad94635..387bd57 100644
--- a/conf/proxy.js
+++ b/conf/proxy.js
@@ -19,17 +19,27 @@
 const httpProxy = require('http-proxy');
 
 const target = process.env.PROXY || '127.0.0.1:9101';
+const wsTarget = process.env.WS || '127.0.0.1:3000';
 
 const proxy = httpProxy.createProxyServer({
   target: `http://${target}`,
   ws: true
 });
-
 proxy.on('error', function(error, req, res) {
   res.writeHead(500, {'Content-Type': 'text/plain'});
   console.error('[Proxy]', error);
 });
 
+const wsProxy = httpProxy.createProxyServer({
+  target: `http://${wsTarget}`,
+  ws: true
+});
+wsProxy.on('error', function(error, req, res) {
+  res.writeHead(500, {'Content-Type': 'text/plain'});
+  console.error('[Proxy]', error);
+});
+
 module.exports = {
-  proxy
+  proxy,
+  wsProxy
 };
\ No newline at end of file