rewrite or internal redirection cycle while internally redirecting to , server: _

오젼·2022년 11월 1일
0

severname _; 을 사용하려면 listen에 default_server;를 적어줘야 한다.

error)

2022/11/01 07:11:40 [error] 18#18: *3 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 172.25.0.3, server: _, request: "GET / HTTP/1.1", host: "jihoh.42.fr"

before)

server {
	listen 7000;
	listen [::]:7000;

	root /var/www/html/wordpress/goaccess;
	index index.html index.htm;
	server_name _;

	location / {
		try_files $uri /index.php?$args;
	}
}

after)

server {
	listen 7000 default_server;
	listen [::]:7000 default_server;

	root /var/www/html/wordpress/goaccess;
	index index.html index.htm;
	server_name _;

	location / {
		try_files $uri /index.php?$args;
	}
}

0개의 댓글