Fixed nginx mod_rewrite templates

devel
alexey 11 hours ago
parent f398decba9
commit e37e8a0d1e

@ -25,20 +25,19 @@ server {
include %home%/%user%/conf/web/%domain%/nginx.hsts.conf*; include %home%/%user%/conf/web/%domain%/nginx.hsts.conf*;
HtaccessEnable on; HtaccessEnable on;
RewriteEngine On;
location ~ /\.(?!well-known\/) { location ~ /\.(?!well-known\/) {
deny all; deny all;
return 404; return 404;
} }
location ~* ^.+\.(jpeg|jpg|png|webp|gif|bmp|ico|svg|css|js|txt)$ {
expires max;
fastcgi_hide_header "Set-Cookie";
}
location / { location / {
RewriteEngine On; RewriteEngine On;
location ~* ^.+\.(jpeg|jpg|png|webp|gif|bmp|ico|svg|css|js)$ {
expires max;
fastcgi_hide_header "Set-Cookie";
}
location ~ [^/]\.php(/|$) { location ~ [^/]\.php(/|$) {
try_files $uri =404; try_files $uri =404;

@ -16,21 +16,20 @@ server {
include %home%/%user%/conf/web/%domain%/nginx.forcessl.conf*; include %home%/%user%/conf/web/%domain%/nginx.forcessl.conf*;
HtaccessEnable on; HtaccessEnable on;
RewriteEngine On;
location ~ /\.(?!well-known\/) { location ~ /\.(?!well-known\/) {
deny all; deny all;
return 404; return 404;
} }
location ~* ^.+\.(jpeg|jpg|png|webp|gif|bmp|ico|svg|css|js|txt)$ {
expires max;
fastcgi_hide_header "Set-Cookie";
}
location / { location / {
RewriteEngine On; RewriteEngine On;
location ~* ^.+\.(jpeg|jpg|png|webp|gif|bmp|ico|svg|css|js)$ {
expires max;
fastcgi_hide_header "Set-Cookie";
}
location ~ [^/]\.php(/|$) { location ~ [^/]\.php(/|$) {
try_files $uri =404; try_files $uri =404;

@ -3,7 +3,7 @@
Name: hestia Name: hestia
Version: 1.9.6 Version: 1.9.6
Release: 4%{dist} Release: 5%{dist}
Summary: Hestia Control Panel Summary: Hestia Control Panel
Group: System Environment/Base Group: System Environment/Base
License: GPLv3 License: GPLv3
@ -184,7 +184,7 @@ fi
%{_tmpfilesdir}/%{name}.conf %{_tmpfilesdir}/%{name}.conf
%changelog %changelog
* Thu Mar 19 2026 Alexey Berezhok <a@bayrepo.ru> - 1.9.6-4 * Thu Mar 19 2026 Alexey Berezhok <a@bayrepo.ru> - 1.9.6-5
- Added nginx with mod_rewrite - Added nginx with mod_rewrite
- Added templates for nginx mod_rewrite activation - Added templates for nginx mod_rewrite activation

Loading…
Cancel
Save