* automatic detect php version and set php extension (for =>8 php version without installing gd, because Debian 11 need libgd3 fix for that) * mapping tld hostname for non-www redirection moved to conf.d and copy that file to remote machine with others existing map-files * some features in this commit not to be a tested in real environment
13 lines
222 B
Plaintext
13 lines
222 B
Plaintext
error_page 418 = @nonwww;
|
|
set $nonwww "";
|
|
if ( $http_host ~* "^www\.") {
|
|
set $nonwww "${nonwww}0";
|
|
}
|
|
if ( $nonwww ~* "^0+$" ) {
|
|
return 418;
|
|
}
|
|
location @nonwww {
|
|
rewrite ^ https://$tld$request_uri permanent;
|
|
}
|
|
|