sudo nano /etc/apache2/sites-available/000-default.conf
<VirtualHost *:80>
        
        ServerAdmin [email protected]
        DocumentRoot /var/www/website_name_laravel/public

       

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined

       
</VirtualHost>
Folder Permission
chmod -R 777 storage
sudo /etc/init.d/apache2 restart
sudo service apache2 restart

Remove index.php from url

sudo nano /etc/apache2/apache2.conf

Change permission folder

<Directory /var/www/>
            Options Indexes FollowSymLinks
            AllowOverride All
            Require all granted
    </Directory>

sudo a2enmod rewrite

sudo systemctl restart apache2

Leave a Comment