add CI env variable to avoid react-script exiting

This commit is contained in:
Sam 2020-04-29 17:04:35 +02:00
parent a66725399e
commit e82db4dcf6
2 changed files with 6 additions and 3 deletions

View File

@ -4,7 +4,7 @@ services:
fittrackee-db:
container_name: fittrackee-db
build: https://github.com/SamR1/mpwo.git#${BRANCH}:fittrackee_api/db
build: https://github.com/SamR1/FitTrackee.git#${BRANCH}:fittrackee_api/db
ports:
- 5435:5432
environment:
@ -13,7 +13,7 @@ services:
fittrackee-api:
container_name: fittrackee-api
build: https://github.com/SamR1/mpwo.git#${BRANCH}:fittrackee_api
build: https://github.com/SamR1/FitTrackee.git#${BRANCH}:fittrackee_api
ports:
- 5001:5000
environment:
@ -30,11 +30,12 @@ services:
fittrackee-client:
container_name: fittrackee-client
build:
context: https://github.com/SamR1/mpwo.git#${BRANCH}
context: https://github.com/SamR1/FitTrackee.git#${BRANCH}
dockerfile: ./fittrackee_client/Dockerfile
args:
- NODE_ENV=development
- REACT_APP_API_URL=${REACT_APP_API_URL}
- CI=true
ports:
- 3007:3000
depends_on:

View File

@ -13,9 +13,11 @@ ENV PATH /usr/src/app/node_modules/.bin:$PATH
ARG REACT_APP_API_URL
ARG NODE_ENV
ARG REACT_APP_ALLOW_REGISTRATION
ARG CI
ENV NODE_ENV $NODE_ENV
ENV REACT_APP_API_URL $REACT_APP_API_URL
ENV REACT_APP_ALLOW_REGISTRATION $REACT_APP_ALLOW_REGISTRATION
ENV CI $CI
# install and cache app dependencies
COPY package.json /usr/src/app/package.json