From f845b3c8af2e3a80d987ad5705351a0297698a81 Mon Sep 17 00:00:00 2001 From: geoffrey stoel Date: Thu, 5 Oct 2017 00:27:21 +0200 Subject: [PATCH] Updated dockerfile to clean alpine image and add python + required libs to make work again. Fixed requirements.txt to fixed twisted version --- Dockerfile | 17 +++++++++++------ requirements.txt | 2 +- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3527d3c8ac..f0f68e8818 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,17 +10,16 @@ # # https://github.com/evennia/evennia/wiki/Running%20Evennia%20in%20Docker # -FROM python:2.7-alpine -MAINTAINER Dan Feeney "feend78@gmail.com" +FROM alpine # install compilation environment -RUN apk update && apk add gcc musl-dev +RUN apk update && apk add python py-pip python-dev py-setuptools gcc musl-dev jpeg-dev zlib-dev # add the project source ADD . /usr/src/evennia # install dependencies -RUN pip install -e /usr/src/evennia +RUN pip install -e /usr/src/evennia --index-url=http://pypi.python.org/simple/ --trusted-host pypi.python.org # add the game source during game builds ONBUILD ADD . /usr/src/game @@ -31,10 +30,16 @@ ONBUILD ADD . /usr/src/game VOLUME /usr/src/game # set the working directory -WORKDIR /usr/src/game +WORKDIR /usr/src + +# init evennia +RUN evennia --init mygame + +WORKDIR /usr/src/mygame +RUN evennia migrate # startup command -CMD ["evennia", "-i", "start"] +# ENTRYPOINT ["evennia", "start"] # expose the telnet, webserver and websocket client ports EXPOSE 4000 4001 4005 diff --git a/requirements.txt b/requirements.txt index 4d007d9532..be3cf558e5 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,7 @@ # Evennia dependencies, for Linux/Mac platforms django > 1.10, < 2.0 -twisted >= 16.0.0 +twisted == 16.0.0 mock >= 1.0.1 pillow == 2.9.0 pytz