diff --git a/README.md b/README.md index d753873..4579395 100644 --- a/README.md +++ b/README.md @@ -30,10 +30,6 @@ Run `docker-compose stop && docker-compose rm`. ## Known Issues -* Recreating the 'app' container resets the mattermost settings. If you modified - settings in System Console or `/mattermost/config/config.json` in the 'app' - container and want to keep them, you should manually update `app/config.json`. - * Do not modify the Listen Address in Service Settings. ## More informations diff --git a/app/Dockerfile b/app/Dockerfile index 369097b..bcdf181 100644 --- a/app/Dockerfile +++ b/app/Dockerfile @@ -14,10 +14,12 @@ exec bin/platform\n'\ RUN wget https://github.com/mattermost/platform/releases/download/v1.2.1/mattermost.tar.gz \ && tar -xvzf mattermost.tar.gz && rm mattermost.tar.gz -ADD config_docker.json / +ADD config/config.json /mattermost/config/ ADD docker-entry.sh / RUN chmod +x /docker-entry.sh ENTRYPOINT /docker-entry.sh +VOLUME ["/mattermost/config"] + EXPOSE 80 diff --git a/app/config_docker.json b/app/config/config.json similarity index 100% rename from app/config_docker.json rename to app/config/config.json diff --git a/app/docker-entry.sh b/app/docker-entry.sh index 09d15e3..0fb3bd3 100644 --- a/app/docker-entry.sh +++ b/app/docker-entry.sh @@ -1,6 +1,6 @@ #!/bin/bash echo Starting Platform -sed -Ei "s/PG_ADDR/$PG_PORT_5432_TCP_ADDR/" /config_docker.json -sed -Ei "s/PG_PORT/$PG_PORT_5432_TCP_PORT/" /config_docker.json +sed -Ei "s/PG_ADDR/$PG_PORT_5432_TCP_ADDR/" /mattermost/config/config.json +sed -Ei "s/PG_PORT/$PG_PORT_5432_TCP_PORT/" /mattermost/config/config.json cd /mattermost/bin -./platform -config=/config_docker.json +./platform