무슨 일이 일어나고 있는지는 GLPI 프로젝트가 파일(js, css, php 등)을 로드하지 않는다는 것입니다.
로컬 URL은 이지만 다음과 같이 http://localhost/glpi-grupo/
Elements의 모든 파일이 누락되었습니다 /glpi-grupo
.http://localhost/style.css
강제로 하위 디렉터리를 로드해야 합니다./glpi-grupo
저는 Docker 컨테이너에서 Nginx와 Traefik을 모두 사용하고 있습니다.
내 트래픽 규칙:
traefik.frontend.rule: Host:localhost; PathPrefixStrip:/glpi-grupo
내 Nginx 구성:
server {
listen 80;
index index.php index.html;
error_log /var/log/nginx/error.log;
access_log /var/log/nginx/access.log;
root /var/www/html;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param SCRIPT_NAME $fastcgi_script_name;
fastcgi_param SERVER_NAME $host;
fastcgi_index index.php;
fastcgi_pass glpi-grupo:9000;
fastcgi_param PATH_INFO $fastcgi_path_info;
}
}