Adjust whitespace for markdownfmt

This commit is contained in:
Joe Ferguson 2017-02-07 14:52:15 -08:00
parent 76e85b2555
commit c0e5710772
1 changed files with 34 additions and 38 deletions

View File

@ -17,36 +17,30 @@ Then there are several options:
1. Get the [sources of this project](https://github.com/xwiki-contrib/docker-xwiki) and build them. 1. Get the [sources of this project](https://github.com/xwiki-contrib/docker-xwiki) and build them.
2. Just pull the xwiki image from DockerHub. 2. Just pull the xwiki image from DockerHub.
## Building ## ## Building
This is the simplest solution and the one recommended. Here are the steps: This is the simplest solution and the one recommended. Here are the steps:
* Install Git and run `git clone https://github.com/xwiki-contrib/docker-xwiki.git` or download the sources from - Install Git and run `git clone https://github.com/xwiki-contrib/docker-xwiki.git` or download the sources from the GitHub UI. Then choose the branch or tag that you wish to use:
the GitHub UI. Then choose the branch or tag that you wish to use: - The `master`branch will get you the latest released version of XWiki
* The `master`branch will get you the latest released version of XWiki - The `8.x` branch will get you the latest released version of XWiki for the 8.x cycle
* The `8.x` branch will get you the latest released version of XWiki for the 8.x cycle - The `8.4.4` tag will get you exactly XWiki 8.4.4.
* The `8.4.4` tag will get you exactly XWiki 8.4.4. - etc.
* etc. - Go the directory corresponding to the configuration you wish to build, for example: `cd xwiki-mysql-tomcat`.
* Go the directory corresponding to the configuration you wish to build, for example: `cd xwiki-mysql-tomcat`. - Run `docker-compose up`
* Run `docker-compose up` - Start a browser and point it to `http://localhost:8080`
* Start a browser and point it to `http://localhost:8080`
Note that if you want to set a custom version of XWiki you can checkout `master` and edit the `env` file and set the Note that if you want to set a custom version of XWiki you can checkout `master` and edit the `env` file and set the values you need in there. It's also possible to override them on the command line with `docker-compose run -e "XWIKI_VERSION=8.4.4"`.
values you need in there. It's also possible to override them on the command line with
`docker-compose run -e "XWIKI_VERSION=8.4.4"`.
Note that `docker-compose up` will automatically build the XWiki image on the first run. If you need to rebuild it Note that `docker-compose up` will automatically build the XWiki image on the first run. If you need to rebuild it you can issue `docker-compose up --build`. You can also build the image with `docker build . -t xwiki-mysql-tomcat:latest` for example.
you can issue `docker-compose up --build`. You can also build the image with
`docker build . -t xwiki-mysql-tomcat:latest` for example.
## Pulling existing image ## ## Pulling existing image
This is a bit more complex since you need to have 2 docker containers running: one for XWiki and one for the database. This is a bit more complex since you need to have 2 docker containers running: one for XWiki and one for the database.
Here's a minimal Docker Compose file using MySQL that you could use as an example (full example Here's a minimal Docker Compose file using MySQL that you could use as an example (full example [here](https://github.com/xwiki-contrib/xwiki-mysql-tomcat/blob/master/docker-compose-using.yml)):
[here](https://github.com/xwiki-contrib/xwiki-mysql-tomcat/blob/master/docker-compose-using.yml):
``` ```yaml
version: '2' version: '2'
services: services:
web: web:
@ -79,26 +73,28 @@ volumes:
## Configuration Options ## Configuration Options
The first time you create a container out of the xwiki image, a shell script (/usr/local/bin/start_xwiki.sh`) is The first time you create a container out of the xwiki image, a shell script (`/usr/local/bin/start_xwiki.sh`) is executed in the container to setup some configuration. The following environment variables can be passed:
executed in the container to setup some configuration. The following environment variables can be passed:
* `MYSQL_USER`: The MySQL user name used by XWiki to read/write to the DB. - `MYSQL_USER`: The MySQL user name used by XWiki to read/write to the DB.
* `MYSQL_PASSWORD`: The MySQL user password used by XWiki to read/write to the DB. - `MYSQL_PASSWORD`: The MySQL user password used by XWiki to read/write to the DB.
## Miscellaneous ## Miscellaneous
Volumes: Volumes:
* Two volumes are created:
* A volume named `<prefix>_mysql-data` that contains the database data. - Two volumes are created:
* A volume named `<prefix>_xwiki-data` that contains XWiki's permanent directory. - A volume named `<prefix>_mysql-data` that contains the database data.
* To find out where those volumes are located on your local host machine you can inspect them with `docker volume inspect <volume name>`. To find the volume name, you can list all volumes with `docker volume ls`. - A volume named `<prefix>_xwiki-data` that contains XWiki's permanent directory.
* Note that on Mac OSX, Docker runs inside the xhyve VM and thus the paths you get when inspecting the volumes are relative to this. Thus, you need to get into that VM if you need to access the volume data. - To find out where those volumes are located on your local host machine you can inspect them with `docker volume inspect <volume name>`. To find the volume name, you can list all volumes with `docker volume ls`.
- Note that on Mac OSX, Docker runs inside the xhyve VM and thus the paths you get when inspecting the volumes are relative to this. Thus, you need to get into that VM if you need to access the volume data.
MySQL: MySQL:
* To issue some mysql commands:
* Find the container id with `docker ps` - To issue some mysql commands:
* Execute bash in the mysql container: `docker exec -it <containerid> bash -l` - Find the container id with `docker ps`
* Once inside the mysql container execute the `mysql` command: `mysql --user=xwiki --password=xwiki` - Execute bash in the mysql container: `docker exec -it <containerid> bash -l`
- Once inside the mysql container execute the `mysql` command: `mysql --user=xwiki --password=xwiki`
# License # License
@ -108,9 +104,9 @@ This repository is also licensed under the [LGPL 2.1](https://github.com/xwiki-c
# Support # Support
* If you wish to raise an issue or an idea of improvement use [XWiki Docker JIRA project](http://jira.xwiki.org/browse/XDOCKER) - If you wish to raise an issue or an idea of improvement use [XWiki Docker JIRA project](http://jira.xwiki.org/browse/XDOCKER)
* If you have questions, use the [XWiki Users Mailing List/Forum](http://dev.xwiki.org/xwiki/bin/view/Community/MailingLists) or use the [XWiki IRC channel](http://dev.xwiki.org/xwiki/bin/view/Community/IRC) - If you have questions, use the [XWiki Users Mailing List/Forum](http://dev.xwiki.org/xwiki/bin/view/Community/MailingLists) or use the [XWiki IRC channel](http://dev.xwiki.org/xwiki/bin/view/Community/IRC)
# Contribute # Contribute
* If you wish to help out on the code, please send Pull Requests on [XWiki Docker GitHub project](https://github.com/xwiki-contrib/docker-xwiki) - If you wish to help out on the code, please send Pull Requests on [XWiki Docker GitHub project](https://github.com/xwiki-contrib/docker-xwiki)