diff --git a/config/environment.js b/config/environment.js index 24eeae0..d37d263 100644 --- a/config/environment.js +++ b/config/environment.js @@ -17,7 +17,7 @@ module.exports = function(environment) { // Here you can pass flags/options to your application instance // when it is created - API_HOST: '', + ENV.APP.API_HOST = 'http://nginx:80', UPDATE_RATE: 200, }, @@ -25,7 +25,7 @@ module.exports = function(environment) { 'default-src': "'none'", 'script-src': "'self' 'unsafe-eval'", 'font-src': "'self'", - 'connect-src': "'self' 192.168.99.100:80", + 'connect-src': "'self' nginx:80", 'img-src': "'self'", 'style-src': "'self' 'unsafe-inline'", 'media-src': "'self'" @@ -44,7 +44,7 @@ module.exports = function(environment) { // ENV.APP.LOG_TRANSITIONS_INTERNAL = true; // ENV.APP.LOG_VIEW_LOOKUPS = true; - ENV.APP.API_HOST = 'http://192.168.99.100:80'; + //ENV.APP.API_HOST = 'http://nginx:80'; } if (environment === 'test') { @@ -60,7 +60,7 @@ module.exports = function(environment) { } if (environment === 'production') { - ENV.baseURL = '/technical/'; + //ENV.baseURL = '/technical/'; } return ENV; diff --git a/docker-compose-dev.yml b/docker-compose-dev.yml index d2fd6ee..63922c8 100644 --- a/docker-compose-dev.yml +++ b/docker-compose-dev.yml @@ -4,8 +4,16 @@ nginx: - ./nginx-conf.d/:/etc/nginx/conf.d/ links: - orion + +ember: + image: danlynn/ember-cli + volumes: + - ./:/myapp/ + links: + - nginx ports: - - "80:80" + - "4200:4200" + command: serve -dev mongo: image: mongo:3.2 diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..d8d6205 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,32 @@ +nginx: + image: nginx + volumes: + - ./nginx-conf.d/:/etc/nginx/conf.d/ + - ./dist/:/www/ + links: + - orion + - ember + ports: + - "80:80" + +ember: + image: danlynn/ember-cli + volumes: + - ./:/myapp/ + command: build -prod + +mongo: + image: mongo:3.2 + command: --smallfiles --nojournal + +orion: + image: fiware/orion + links: + - mongo + command: -dbhost mongo + +playback: + image: acs/playback + links: + - orion + command: orion:1026 m1_S1_ElectricalGrid_data.txt diff --git a/nginx-conf.d/default.conf b/nginx-conf.d/default.conf index 3c37efe..babdf7e 100644 --- a/nginx-conf.d/default.conf +++ b/nginx-conf.d/default.conf @@ -28,6 +28,11 @@ server { proxy_pass http://orion:1026/; } + # website location + location / { + root /www; + } + error_page 404 /404.html; location = /404.html { root /usr/share/nginx/html;