I'm having difficulty getting mod_rewrite to work in Apache2 on Debian 10. I enabled the extension with
a2enmod rewrite
systemctl restart apache2
And had no errors and can see the module in
apachectl -M
...
rewrite_module (shared)
...
Although when I add it to my vhost in the sites-available
<VirtualHost *:80>
ServerName default.nothing
ServerAlias www.default.nothing
DocumentRoot /var/www/html/public_html/00-default
<Directory "/volume/dev/html/public_html/00-default">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
RewriteEngine on
RewriteRule ^192.168.20.87$ nothing
</Directory>
<IfModule mpm_user_module>
ServerEnvironment apache apache
</IfModule>
</VirtualHost>
Hoping that it would rewrite the url http://192.168.20.87/page.php as http://nothing/page.php in the browser tab. No matter what I put into RewriteRule nothing seems to happen. I'm sure I'm doing something