Today colleagues asked to build a MediaWiki in the Docker to find a MediaWiki mirror, or according to the information they gave to the whole long time. Let's look at the installation tutorials.
System: CentOS 6.5 (64-bit)
1. Download MediaWiki mirror
Docker pull Synctree/mediawiki:latest
2. Prepare before starting
MKDIR/SRV/DOCKER/MEDIAWIKI/MYSQL-PV
Mkdir/srv/docker/mediawiki/mediawiki
3.docker start MediaWiki
Docker run--name some-mysql-tid \
-e ' db_name=mediawiki ' \
-E ' Db_user=app '-e ' db_pass=secure ' \
-v/srv/docker/mediawiki/mysql:/var/lib/mysql \
Sameersbn/mysql:latest
Docker run--name mediawiki-tid \
--link some-mysql:mysql \
&N bsp; -P 8888:80 \
-e mediawiki_db_user=app-e mediawiki_db_password=secure \
& nbsp; -v/srv/docker/mediawiki/mediawiki:/home/mediawiki/data \
synctree/ MediaWiki
4. Go to browser configuration
Open Browser, enter http://ip:8888, and then start configuration, I'll just say the database connection This page, the following figure
Notice the red arrow in the figure, so you can enter it to connect to the Docker database.
Well, the middle of the steps are also omitted, only the last step of the download file can be thrown into the Docker MediaWiki/var/www/html directory.
5.docker container and host copy transfer files to each other
Docker Ps-a
Docker Inspect-f ' {{. Id} ' MediaWiki
CP ~/localsettings.php/var/lib/docker/devicemapper/mnt/ 4fc23b875bb0327a208e1ad615e7fba60d9df861f08a2004f9c94e5b1b3ca4d9/rootfs/var/www/html/
Can see, has been thrown in, and finally a picture for everyone to see, this is the situation after the login.
All right, here we go.