Docker 部署 GLPI(IT 资产管理软件系统)

GLPI 简介

GLPI open source tool to manage Helpdesk and IT assets

GLPI stands for Gestionnaire Libre de Parc Informatique(法语 资讯设备自由软件 的缩写) is a Free Asset and IT Management Software package, that provides ITIL Service Desk features, licenses tracking and software auditing.

shell 复制代码
https://glpi-project.org/
https://github.com/glpi-project/glpi
https://hub.docker.com/r/diouxx/glpi
# 官方安装 glpi 文档
https://glpi-install.readthedocs.io/en/latest/install/wizard.html#end-of-installation

https://www.cnblogs.com/wuhanjiayou/p/18060193/GLPI
https://blog.51cto.com/weicun/1943941

1. 安装 Docker CE

shell 复制代码
curl https://download.docker.com/linux/centos/docker-ce.repo -o /etc/yum.repos.d/docker.repo
yum install docker-ce -y && sudo systemctl enable --now docker
docker -v && docker search hello-world

2. 编写 compose.yaml 文件

shell 复制代码
[root@localhost ~]# mkdir glpi && cd glpi
[root@localhost glpi]# cat <<EOF > compose.yaml
services:
#MariaDB Container
  mariadb:
    image: mariadb:11.6.2	# 指定版本
    container_name: mariadb
    hostname: mariadb
    environment:
      - MARIADB_ROOT_PASSWORD=Root@2025
      - MARIADB_DATABASE=glpidb
      - MARIADB_USER=glpi_user
      - MARIADB_PASSWORD=glpi
    volumes:
      - ./mysql:/var/lib/mysql
    restart: always
#GLPI Container
  glpi:
    image: diouxx/glpi
    container_name : glpi
    hostname: glpi
    volumes:
      - ./html/glpi/:/var/www/html/glpi
    environment:
      - TIMEZONE=Asia/Shanghai
    ports:
      - "80:80"
    restart: always
    depends_on:
      - mariadb
EOF

3. 通过 compose.yml 运行容器

shell 复制代码
[root@localhost glpi]# docker compose up -d

[+] Running 14/10

 ✔ mariadb Pulled                                    25.9s 

 ✔ glpi Pulled                                     31.2s                                          

[+] Running 3/3

 ✔ Network glpi_default Created                             0.4s 

 ✔ Container mariadb   Started                             1.4s 

 ✔ Container glpi    Started                             1.6s 
 
 [root@localhost glpi]# docker ps && docker images
CONTAINER ID   IMAGE          COMMAND                   CREATED          STATUS          PORTS                                        NAMES
48fc0748ac84   diouxx/glpi    "/opt/glpi-start.sh"      41 minutes ago   Up 41 minutes   0.0.0.0:80->80/tcp, :::80->80/tcp, 443/tcp   glpi
9e11eb0fdbba   mariadb:10.7   "docker-entrypoint.s..."   43 minutes ago   Up 43 minutes   3306/tcp                                     mariadb
REPOSITORY    TAG       IMAGE ID       CREATED         SIZE
diouxx/glpi   latest    08472c90fa20   2 months ago    328MB
mariadb       10.7      895b6c8829c3   21 months ago   396MB

4. 数据库配置

shell 复制代码
# 该信息在 compose.yaml 文件中已定义
SQL 服务器地址:mariadb
SQL 账号:glpi_user
SQL 密码: glpi
相关推荐
绘梨衣5471 天前
Docker+FastAPI+MySQL 项目部署报错汇总
mysql·docker·fastapi
cui_ruicheng1 天前
Linux进程间通信(三):System V IPC与共享内存
linux·运维·服务器
ACP广源盛139246256731 天前
IX8024与科学大模型的碰撞@ACP#筑牢科研 AI 算力高速枢纽分享
运维·服务器·网络·数据库·人工智能·嵌入式硬件·电脑
百年੭ ᐕ)੭*⁾⁾1 天前
docker使用neo4j
docker·容器·neo4j
峥无1 天前
Linux系统编程基石:静态库·动态库·ELF文件·进程地址空间全景图
linux·运维·服务器
码云数智-大飞1 天前
本地部署大模型:隐私安全与多元优势一站式解读
运维·网络·人工智能
Harvy_没救了1 天前
【网络部署】 Win11 + VMware CentOS8 + Nginx 文件共享服务 Wiki
运维·网络·nginx
春风有信1 天前
【2026.05.01】Windows10安装Docker Desktop 4.71.0.0步骤及问题解决
运维·docker·容器
2401_873479401 天前
断网时如何实时判断IP归属?嵌入本地离线库,保障风控不中断
运维·服务器·网络
守城小轩1 天前
基于Chrome140的Yahoo自动化(关键词浏览)——需求分析&环境搭建(一)
运维·自动化·chrome devtools·浏览器自动化·指纹浏览器·浏览器开发