Generating the correct URL for service models
Change-Id: I2b004176b74043f46ee96b0bad4f0659422836da
diff --git a/conf/proxy.js b/conf/proxy.js
index fedbf72..d2459d8 100644
--- a/conf/proxy.js
+++ b/conf/proxy.js
@@ -1,11 +1,13 @@
const httpProxy = require('http-proxy');
+const target = process.env.PROXY || '192.168.46.100';
+
const proxy = httpProxy.createProxyServer({
- target: 'http://192.168.46.100:9101'
+ target: `http://${target}:9101`
});
const extensionsProxy = httpProxy.createProxyServer({
- target: 'http://192.168.46.100/spa/'
+ target: `http://${target}/spa/`
});
proxy.on('error', function(error, req, res) {