scragg0x / realms-wiki

Git based wiki inspired by Gollum
http://realms.io
GNU General Public License v2.0
833 stars 90 forks source link

Updated Dockerfile #130

Closed lanrat closed 8 years ago

lanrat commented 8 years ago
lanrat commented 8 years ago

@scragg0x do you mind updating realms/realms-wiki on the docker hub to use this as a new docker file for automated builds and adding ubuntu:trusty as repository link?

This would make the docker hub automatically update the docker image automatically every time there is an update on github. https://hub.docker.com/r/realms/realms-wiki/~/settings/automated-builds/

Thanks!

stevezau commented 8 years ago

@lanrat thanks for updating this.. i don't think this has been updated on docker hub yet? Are you using it standalone?

lanrat commented 8 years ago

I'm using my own local build. It would be nice if @scragg0x could setup the automated build as mentioned in my previous comment.

scragg0x commented 8 years ago

I updated the docker image. I don't yet have a fully automated build process yet. Although I do have a script to publish to pypi and docker when I create a new version.

lanrat commented 8 years ago

@scragg0x if you follow the steps listed here (https://docs.docker.com/docker-hub/builds/) the Docker Hub will create an automated build from the git repository.

stevezau commented 8 years ago

@lanrat any reason why you used a virtualenv here? Seems unnecessary for a docker container?

Also, I assume wiki user was used for security reasons? Is that also really necessary? (I'm not that familiar with security best practice on docker)

lanrat commented 8 years ago

@stevezau virtualenv is not strictly required but it does not hurt either. I used to to try to keep the dockerfile inline with the install instructions in the README.

Without the wiki user the docker container would run as root which is a bad security practice.

stevezau commented 8 years ago

@lanrat another question, there is no support for setting a custom wiki json file? Should that be added or is there another way to do it?

lanrat commented 8 years ago

@stevezau any individual custom options can be specified as an environment variable: docker run -e REALMS_VAR=VALUE. An entire custom config can be specified as a volume: docker run -v /path/to/realms-wiki.json:/home/wiki/realms-wiki/realms-wiki.json.

stevezau commented 8 years ago

@lanrat good point.. hmm perhaps an update to the README is in order.