-
Notifications
You must be signed in to change notification settings - Fork 168
Docker instructions
Eduardo Fernandes edited this page Oct 20, 2019
·
5 revisions
You can use Docker to run the wiki!
First thing, create your .env file.
You can set the port where you want to use Wikitten by changing the HTTP_PORT and use another library folder by changing LIBRARY_FOLDER.
The LIBRARY_FOLDER will be mounted by docker-composer in /var/www/html/library.
$ cp docker/.env.example docker/.env
$ cat docker/.env
HTTP_PORT=9000
LIBRARY_FOLDER=../libraryRemember that docker-composer will mount the LIBRARY in /var/www/html/library, make sure your config.php reflect that or has the LIBRARY line commented.
// define('LIBRARY', '/path/to/wiki/library');Build the images and run the container.
cd Wikitten/docker
sudo docker-compose build --force-rm --no-cache
sudo docker-compose up --detach --force-recreate --remove-orphans'With these commands docker and docker-compose will:
- Create a
wikittenimage based ondocker/Dockerfile. - Start a
wikittencontainer and- mount the
Wikittenfolder to the container's/var/www/htmlfolder; - mount the
LIBRARYfolder to the container's/var/www/html/libraryfolder; - mount the
docker/logsfolder to the container's/var/log/apache2folder;
- mount the
Wikitten will be then available at http://localhost:9000.
This will stop you having to run the above commands and just run a single one:
docker-compose up