Skip to content

Commit

Permalink
AB#26410 Make port ibf service port configurable locally
Browse files Browse the repository at this point in the history
  • Loading branch information
Ruben committed Mar 11, 2024
1 parent c8d512e commit b478b19
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
6 changes: 3 additions & 3 deletions docker-compose.override.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@ version: '3.8'

services:
ibf-api-service:
command: ['npm', 'run', 'start:dev']
command: [ 'npm', 'run', 'start:dev' ]
environment:
- NODE_ENV=development
ports:
- 3000:3000
- ${LOCAL_PORT_IBF_SERVICE}:3000
depends_on:
- ibf-local-db
networks:
- web-server-network
- api-network

ibf-dashboard:
entrypoint: ['echo', 'Service ibf-dashboard disabled']
entrypoint: [ 'echo', 'Service ibf-dashboard disabled' ]

ibf-geoserver:
ports:
Expand Down
2 changes: 2 additions & 0 deletions example.env
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ DB_PASSWORD=
SECRET=
RESET_SECRET=
NODE_ENV=
LOCAL_PORT_IBF_SERVICE=4000 # If you do not specify a port, the default port is 3000. this only applies to the override docker-compose file

# Token used to acces the water point data at https://data.waterpointdata.org/profile/edit/developer_settings
WATERPOINTDATA_TOKEN=
# This password is only needed for production
Expand Down
2 changes: 1 addition & 1 deletion interfaces/IBF-dashboard/src/environments/environment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

export const environment = {
configuration: 'development',
apiUrl: 'http://localhost:3000/api', // API
apiUrl: `http://localhost:${process.env['LOCAL_PORT_IBF_SERVICE'] ? process.env['LOCAL_PORT_IBF_SERVICE'] : 3000}/api`, // API
useServiceWorker: false, // feature-flags
geoserverUrl: 'http://localhost:8081/geoserver/ibf-system/wms', // geoserver
ibfSystemVersion: 'v0.0.0', // version
Expand Down

0 comments on commit b478b19

Please sign in to comment.