Skip to content

Commit

Permalink
Merge d1dea0c into 550ff20
Browse files Browse the repository at this point in the history
  • Loading branch information
judeinno committed Mar 19, 2019
2 parents 550ff20 + d1dea0c commit a560365
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 45 deletions.
13 changes: 1 addition & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,5 @@ COPY --from=build-deps /usr/src/app/docker/default.conf /etc/nginx/conf.d/
# Make port 80 available to the world outside the container
EXPOSE 80

# Copy .env file and shell script to container
WORKDIR /usr/share/nginx/html
COPY ./init.sh .
COPY .env .

# Add bash
RUN apk add --no-cache bash

# Make our shell script executable
RUN chmod +x init.sh

# Start Nginx server
CMD ["/bin/bash", "-c", "/usr/share/nginx/html/init.sh && nginx -g \"daemon off;\""]
CMD ["nginx", "-g", "daemon off;"]
4 changes: 4 additions & 0 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ version: '2.1'
services:
oclclient:
image: openmrs/ocl-client:local
environment:
- REACT_APP_OCL_API_HOST=${REACT_APP_OCL_API_HOST:-https://api.qa.openconceptlab.org/}
- REACT_APP_TRADITIONAL_OCL_HOST=${REACT_APP_TRADITIONAL_OCL_HOST:-https://qa.openconceptlab.org}
- ENVIRONMENT=${ENVIRONMENT:-local}
ports:
- 8081:80
restart: always
Expand Down
29 changes: 0 additions & 29 deletions init.sh

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"react-notify-toast": "^0.4.0",
"react-redux": "^5.0.7",
"react-render-html": "^0.6.0",
"react-router": "^4.4.0",
"react-router": "^4.3.1",
"react-router-dom": "^4.2.2",
"react-scripts": "1.1.4",
"react-select": "^2.0.0-beta.7",
Expand Down
1 change: 0 additions & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
<meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-config" content="%PUBLIC_URL%/images/favicons/browserconfig.xml">
<meta name="theme-color" content="#ffffff">
<script src="./env-config.js"></script>
<title>OpenMRS OCL client</title>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.0.11/css/all.css" integrity="sha384-p2jx59pefphTFIpeqCcISO9MdVfIm4pNnsL08A6v5vaQc4owkQqxMV8kg4Yvhaw/" crossorigin="anonymous">
</head>
Expand Down
4 changes: 2 additions & 2 deletions src/config/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export default {
OCL_API_HOST: (window.env && window.env.OCL_API_HOST) || 'https://api.qa.openconceptlab.org/',
TRADITIONAL_OCL: (window.env && window.env.TRADITIONAL_OCL_HOST) || 'https://qa.openconceptlab.org',
OCL_API_HOST: (process.env && process.env.REACT_APP_OCL_API_HOST) || 'https://api.qa.openconceptlab.org/',
TRADITIONAL_OCL: (process.env && process.env.REACT_APP_TRADITIONAL_OCL_HOST) || 'https://qa.openconceptlab.org',
};

0 comments on commit a560365

Please sign in to comment.