diff --git a/docker-compose.env b/docker-compose.env index e69de29..a71250e 100644 --- a/docker-compose.env +++ b/docker-compose.env @@ -0,0 +1 @@ +LIBRARY_SOCKET_HOST=ws://importapi:3001 \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 0feaa0b..7911eb3 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -78,7 +78,6 @@ services: - "3001:3001" environment: SERVICES: api - DOCKER_RABBITMQ_CONNECTION_STRING: 'amqp://user:bitnami@rabbitmq:5672' labels: - "traefik.enable=true" - "traefik.http.routers.threetwo-import-api.rule=Host(`localhost`)" diff --git a/src/client/constants/endpoints.ts b/src/client/constants/endpoints.ts index 02745e4..c021c6e 100644 --- a/src/client/constants/endpoints.ts +++ b/src/client/constants/endpoints.ts @@ -38,7 +38,7 @@ export const IMPORT_SERVICE_BASE_URI = hostURIBuilder({ export const SOCKET_BASE_URI = hostURIBuilder({ protocol: "http", - host: process.env.DOCKER_HOST || "localhost", + host: process.env.LIBRARY_SOCKET_HOST || "localhost", port: "3001", apiPath: `/`, }); diff --git a/webpack.config.js b/webpack.config.js index 5d82061..e9fc58c 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -99,6 +99,9 @@ module.exports = (env) => { }), new webpack.DefinePlugin({ "process.env.DOCKER_HOST": JSON.stringify(process.env.DOCKER_HOST), + "process.env.LIBRARY_SOCKET_HOST": JSON.stringify( + process.env.LIBRARY_SOCKET_HOST, + ), }), new MiniCssExtractPlugin({ filename: "./css/[name].css",