File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ export default {
4848 // Axios module configuration: https://go.nuxtjs.dev/config-axios
4949 axios : {
5050 // Workaround to avoid enforcing hard-coded localhost:3000: https://github.com/nuxt-community/axios-module/issues/308
51- baseURL : '/'
51+ baseURL : ( process . env . NODE_ENV === 'production' ? '/' : 'http://localhost:8081/' )
5252 } ,
5353
5454 // Vuetify module configuration: https://go.nuxtjs.dev/config-vuetify
Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ export default {
134134 },
135135 methods: {
136136 async longPolling () {
137- this .$axios .$get (' http://localhost:8081 /poll' , {timeout: 10000 }).then ((response ) => {
137+ this .$axios .$get (' /poll' , {timeout: 10000 }).then ((response ) => {
138138 try {
139139 response .body = JSON .parse (response .body );
140140 } catch (e) {
@@ -159,7 +159,7 @@ export default {
159159 const time = this .time ();
160160 // Could be using Swagger generated client, but it would validate fields!
161161 this .$axios .$post (
162- ' http://localhost:8081 /forward' ,
162+ ' /forward' ,
163163 {
164164 endpoint: this .form .core .urlSiSamu + endpoint,
165165 data: this .form .clickToCall
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ const path = require('path');
33const config = {
44 ROOT_DIR : __dirname ,
55 URL_PORT : process . env . PORT || 8081 ,
6- URL_PATH : 'http://localhost' ,
6+ URL_PATH : process . env . URL || 'http://localhost' ,
77 BASE_VERSION : '/lrm/api' ,
88 CONTROLLER_DIRECTORY : path . join ( __dirname , 'controllers' ) ,
99 PROJECT_DIR : __dirname ,
You can’t perform that action at this time.
0 commit comments