react refresh 404 - mowen0303/note GitHub Wiki
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.html$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule . /index.html [L]
</IfModule>
rfe: https://tecadmin.net/enable-disable-modules-in-apache2-on-ubuntu-linuxmint/
We use a2enmod command to enable modules in Apache2 web server. For example, if we need to enable the Apache rewrite module use the following command.
sudo a2enmod rewrite
Then reload the Apache configuration.
sudo systemctl relaod apache2
Check Modules Status
sudo a2query -m rewrite
Output
rewrite (enabled by site administrator)
List Apache2 Modules
sudo a2query -m
open file on server /etc/apache2/apache2.conf and change AllowOverride None to AllowOverride All
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>