Skip to content

Commit

Permalink
build: added env var that should work
Browse files Browse the repository at this point in the history
  • Loading branch information
kevkevinpal committed Apr 27, 2023
1 parent aa6091f commit d2e0c97
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ RUN yarn cache clean && yarn install --ignore-scripts

COPY . /usr/src/app

ARG REACT_APP_API_URL

ENV REACT_APP_API_URL $REACT_APP_API_URL

RUN yarn run build

FROM nginx:alpine
Expand Down
2 changes: 1 addition & 1 deletion src/constants/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const isDevelopment = !!(
);

export const API_URL =
process.env.REACT_DEV_API_URL ||
process.env.REACT_APP_API_URL ||
apiUrlFromSwarmHost() ||
"https://knowledge-graph.sphinx.chat";

Expand Down

0 comments on commit d2e0c97

Please sign in to comment.