Skip to content

Instantly share code, notes, and snippets.

@link2qaiser
Last active February 6, 2023 14:20
Show Gist options
  • Save link2qaiser/43d6ab3dc33fc4523c7085e5520630ab to your computer and use it in GitHub Desktop.
Save link2qaiser/43d6ab3dc33fc4523c7085e5520630ab to your computer and use it in GitHub Desktop.
enable mode rewrite ubuntu apache
sudo a2enmod rewrite
and restart the apache
sudo service apache2 restart
To use mod_rewrite from within .htaccess files (which is a very common use case), edit the default VirtualHost with
sudo nano /etc/apache2/sites-available/000-default.conf
Below “DocumentRoot /var/www/html” add the following lines:
<Directory "/var/www/html">
AllowOverride All
</Directory>
Restart the server again:
sudo service apache2 restart
-------------------------
sudo chmod 755 -R html && sudo chmod -R o+w html/storage && cd html && sudo php artisan cache:clear && sudo composer dump-autoload
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment