Merge branch 'new-project-structure' of gitlab.com:saburly/wiaas/new-wiaas into new-project-structure
This commit is contained in:
@@ -1,10 +1,6 @@
|
|||||||
FROM php:7.0-apache
|
FROM php:7.0-apache
|
||||||
ARG API_URL
|
ARG API_URL
|
||||||
ENV REACT_APP_API_URL=${API_URL}
|
ENV REACT_APP_API_URL ${API_URL}
|
||||||
|
|
||||||
ENV REACT_APP_TEST_URL ${API_URL}
|
|
||||||
ENV REACT_APP_PROD_URL ${APIP_URL}
|
|
||||||
ENV REACT_APP_DEV_URL ${API_URL}
|
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y git unzip gnupg
|
RUN apt-get update && apt-get install -y git unzip gnupg
|
||||||
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash -
|
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash -
|
||||||
|
|||||||
@@ -1,21 +1,7 @@
|
|||||||
import processReducer from "./reducers/orders/processReducers";
|
|
||||||
|
|
||||||
const APPLICAITON_MODE = 'DEV';
|
|
||||||
const APPLICATION_NAME = 'Co-Market';
|
const APPLICATION_NAME = 'Co-Market';
|
||||||
const API_VERSION = 'v2';
|
const API_VERSION = 'v2';
|
||||||
|
|
||||||
const API_SERVER_BASE = (() => {
|
const API_SERVER_BASE = process.env.REACT_APP_API_URL;
|
||||||
if(APPLICAITON_MODE === 'TEST'){
|
const API_SERVER = API_SERVER_BASE;
|
||||||
return process.env.REACT_APP_TEST_URL;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(APPLICAITON_MODE === 'PROD'){
|
export {API_SERVER_BASE, API_SERVER, APPLICATION_NAME}
|
||||||
return process.env.REACT_APP_PROD_URL;
|
|
||||||
}
|
|
||||||
|
|
||||||
return process.env.REACT_APP_DEV_URL;
|
|
||||||
})();
|
|
||||||
|
|
||||||
const API_SERVER = API_SERVER_BASE
|
|
||||||
|
|
||||||
export {APPLICAITON_MODE, API_SERVER_BASE, API_SERVER, APPLICATION_NAME}
|
|
||||||
|
|||||||
Reference in New Issue
Block a user