rgfincher
Basic Pleskian
- Server operating system version
- Ubuntu 22.04
- Plesk version and microupdate number
- 18.0.76 Update #6
I am attempting to use a domain.map file full of redirects.
The location of the file is : /var/www/vhosts/system/MyDomain/conf/domain.map
I am putting the following into the Apache & Nginx settings :
RewriteEngine On
RewriteMap redirects txt:/var/www/vhosts/system/$MyDomain/conf/domain.map
RewriteCond ${redirects:/$1|NOT_FOUND} !NOT_FOUND
RewriteRule ^(.*)$ https://www.MyDomain${redirects:/$1} [R=301,L,NE]
The file is being read, because I can see it in lsof output
The file ownership and permissions are :
-rw-rw-r-- 1 www-data www-data 1379486 Jun 17 21:02 domain.map
No errors appear to be generated in any log files I can find, including the ones in /var/log/apache2/error.log and /var/log/plesk-php??-fpm/error.log
I have tried temporarily disabling the Web Application Firewall
Grateful for any comments.
The location of the file is : /var/www/vhosts/system/MyDomain/conf/domain.map
I am putting the following into the Apache & Nginx settings :
RewriteEngine On
RewriteMap redirects txt:/var/www/vhosts/system/$MyDomain/conf/domain.map
RewriteCond ${redirects:/$1|NOT_FOUND} !NOT_FOUND
RewriteRule ^(.*)$ https://www.MyDomain${redirects:/$1} [R=301,L,NE]
The file is being read, because I can see it in lsof output
The file ownership and permissions are :
-rw-rw-r-- 1 www-data www-data 1379486 Jun 17 21:02 domain.map
No errors appear to be generated in any log files I can find, including the ones in /var/log/apache2/error.log and /var/log/plesk-php??-fpm/error.log
I have tried temporarily disabling the Web Application Firewall
Grateful for any comments.