Created
September 3, 2014 19:07
-
-
Save rochacon/dd57746053cdbe9aed23 to your computer and use it in GitHub Desktop.
AWS Beanstalk Python web app on Docker
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"AWSEBDockerrunVersion": "1", | |
"Image": { | |
"Update": "false" | |
}, | |
"Ports": [ | |
{"ContainerPort": "8080"} | |
], | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM python:2 | |
RUN apt-get update -y && apt-get install -y wget && apt-get clean | |
RUN wget -qO/usr/local/bin/forego https://godist.herokuapp.com/projects/ddollar/forego/releases/0.11.0/linux-amd64/forego && chmod +x /usr/local/bin/forego | |
RUN pip install waitress | |
ADD . /app | |
RUN pip install -r /app/requirements.txt | |
WORKDIR /app | |
EXPOSE 8080 | |
USER nobody | |
ENTRYPOINT ["/usr/local/bin/forego"] | |
CMD ["start", "web"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
web: waitress-serve --port 8080 app:app |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment