Skip to content

Commit

Permalink
Updated Dockerfile to be flexible (#66)
Browse files Browse the repository at this point in the history
* Updated Dockerfile to be flexible

* Update
  • Loading branch information
jinhyukchang authored Jul 25, 2019
1 parent a6eedf7 commit 16415ea
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,16 @@ $ docker run -p 5000:5000 amundsendev/amundsen-metadata
$ curl -v http://localhost:5000/healthcheck
```

## Instructions to start the service from Docker image with gunicorn (production use case)
Note that there below command uses default config of gunicorn. Please visit [Gunicorn homepage](https://gunicorn.org/ "Gunicorn") for more information.
```bash
$ docker pull amundsendev/amundsen-metadata:latest
$ docker run -p 5000:5000 amundsendev/amundsen-metadata gunicorn --bind 0.0.0.0:5000 metadata_service.metadata_wsgi

-- In different terminal, verify getting HTTP/1.0 200 OK
$ curl -v http://localhost:5000/healthcheck
```

## Production environment
By default, Flask comes with Werkzeug webserver, which is for development. For production environment use production grade web server such as [Gunicorn](https://gunicorn.org/ "Gunicorn").

Expand Down
4 changes: 2 additions & 2 deletions public.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ WORKDIR /app
COPY . /app
RUN pip3 install -r requirements.txt
RUN python3 setup.py install
RUN pip3 install gunicorn

ENTRYPOINT [ "python3" ]
CMD [ "metadata_service/metadata_wsgi.py" ]
CMD [ "python3", "metadata_service/metadata_wsgi.py" ]
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from setuptools import setup, find_packages

__version__ = '1.0.15'
__version__ = '1.0.16'


setup(
Expand Down

0 comments on commit 16415ea

Please sign in to comment.