Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker support #87

Open
wants to merge 3 commits into
base: staging
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
FROM ubuntu
RUN apt-get update
RUN apt-get install nginx -y
ADD trademapper /var/www/html/
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx","-g","daemon off;"]
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,10 @@ We have more detailed information on the [wiki](https://github.com/trademapper/t
* [How to use TradeMapper](https://github.com/trademapper/trademapper-js/wiki/How-to-use-trademapper)
* [Getting set up for development](https://github.com/trademapper/trademapper-js/wiki/Development)
* [A guide to the code](https://github.com/trademapper/trademapper-js/wiki/Guide-to-the-code)

Docker usage
-------------

From the root directory run docker build -t trademapper:0.1 . to build the container image; run docker run -d -p 80:80 trademapper:0.1 to start the container .

Remember any changes to the codebase will require a new docker build and new docker run ( remember to kill the previosu container )
8 changes: 8 additions & 0 deletions nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
server {
listen 80;
server_name trademapper;
location / {
root /var/www/html/trademapper;
try_files $uri /index.html;
}
}