Install and run an GLPI instance with docker
docker run --name glpi -p 80:80 -d diouxx/glpi
docker run --name glpi --link yourdatabase:mysql -p 80:80 -d diouxx/glpi
For an usage on production environnement or daily usage, it's recommanded to use a data container for persistent data.
- First, create data container
docker create --name glpi-data --volume /var/www/html/glpi:/var/www/html/glpi busybox /bin/true
- Then, you link your data container with GLPI container
docker run --name glpi --hostname glpi --link mysql:mysql --volumes-from glpi-data -p 80:80 -d diouxx/glpi
Enjoy :)
To deploy with docker compose, you use docker-compose.yml and mysql.env file. You can modify mysql.env to personalize settings like :
- MySQL root password
- GLPI database
- GLPI user database
- GLPI user password
To deploy, just run the following command on the same directory as files
docker-compose up -d