How to deploy GLPI using Docker

Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
"The best Linux newsletter on the web"

Hello, friends. We continue playing with Docker. Today is the turn to deploy GLPI using Docker, so you have another way to use and install it.

Introduction – Docker

Docker is a software development platform for virtualization with multiple operating systems running on the same host. This is made possible by containers that are distributed as images.

The system is very lightweight because it does not incorporate an operating system, which also allows for better use of resources. Docker also allows applications to be isolated, which is very useful for testing without bringing down the client’s production server.

Meanwhile, GLPI is a web application that allows us to deploy a fleet management system. It has also evolved and with it, you can also manage hardware, software, and data centers by linking the asset inventory to the helpdesk.

Today we will use both technologies.

Deploy GLPI using Docker

The first thing we need to do is learn how to install Docker. As in this post, I used Ubuntu 22.04 as the system, you can learn how to install Docker on it and obviously Docker Compose.

Once both tools are up to speed, you can then create a folder where GLPI will be and access it

mkdir glpi
cd glpi

Now create a file called docker-compose.yml.

nano docker-compose.yml

And add this content in the

version: "3.2"


    image: mariadb:10.7
    container_name: mariadb
    hostname: mariadb
      - /var/lib/mysql:/var/lib/mysql
      - MARIADB_DATABASE=glpidb
      - MARIADB_USER=glpi_user
    restart: always

    image: diouxx/glpi
    container_name : glpi
    hostname: glpi
      - "80:80"
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro
      - /var/www/html/glpi/:/var/www/html/glpi
      - TIMEZONE=America/Chicago
    restart: always

It is simple content, but let’s take a look at it anyway. In this file two services are inserted which are MariaDB and GLPI. Remember that GLPI requires a database handler like MariaDB.

In the first section is MariaDB with a volume for data persistence. The information contained in environment can be modified as you like (user, passwords, and database name).

In the other section there is GLPI. Here it is easier because there are fewer fields. You expose the host port 80 for the application and mount the volumes for the data persistence and the timezone that you have to modify.

Save the changes and close the editor.

Now apply all the changes by running

sudo docker compose up -d
Deploying GLPI using Docker
Deploying GLPI using Docker

If all goes well, you will see something similar to this.

Log in to GLPI

Now all that remains is to complete the installation via the web browser by going to http:your-server.

You will see the welcome screen and language selection.

GLPI welcome screen
GLPI welcome screen

Go through the whole process and in the database connection, enter the values that are in the file.

GLPI database connection
GLPI database connection

If all goes well, you will see this.

Database connection successful
Database connection successful

Continue the entire process, until you are given the login credentials. Then, you will see the login screen, and you will see the dashboard.

GLPI running

This is it.


Docker is a marvel with which we can deploy applications quickly and easily. Today, you have learned how to do it with GLPI.

How to install GLPI on Ubuntu 22.04

Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
"The best Linux newsletter on the web"
I am Angelo. A systems engineer passionate about Linux and all open-source software. Although here I'm just another member of the family.


Please enter your comment!
Please enter your name here

Latest articles

Join us on Facebook