How to resolve 403 Forbidden on Symfony website

I just started a project and when I try to access the website I get this error:

Forbidden

You don't have permission to access this resource.

Here’s the config of my website:

    <VirtualHost *:80>
        ServerName portfolio.lxc

        ServerAdmin [email protected]
        DocumentRoot /var/www/portfolio/public
        <Directory /var/www/portfolio/public>
                Options Indexes FollowSymLinks
                AllowOverride All
                Require all granted
        </Directory>

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

</VirtualHost>

I enabled my website like this

a2ensite portfolio
systemctl reload apache2

And then this error. When I looked on the Internet, it was said to allow "Options FollowSymLinks" but it’s already allowed on my conf. I tried

chmod -R 777 /var/www/portfolio/

But I still get this error.

Source: Symfony Questions

Was this helpful?

0 / 0

Leave a Reply 0

Your email address will not be published. Required fields are marked *