Score:0

Still get 403 forbidden, after moved Apache root folder in /home directory and enabled config file?

tj flag

I want to move root directory from var/html/www to home/mitacheto/projects, where "mitacheto" is mine username. What I already did:

1 - Opened etc/apache2/sites-enabled/000-default.conf and changed DocumentRoot, like this:

DocumentRoot /home/mitacheto/projects

2 - Added this to the end of the same file etc/apache2/sites-enabled/000-default.conf:

<Directory /home/mitacheto/projects>
    Options FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

3 - I changed Directory in etc/apache2/apache2.conf, so it looks like this:

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

<Directory /usr/share>
    AllowOverride None
    Require all granted
</Directory>

<Directory /home/mitacheto/projects>
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

4 - Finally I restarted the apache service:

sudo service apache2 restart

When I open localhost, I got:

Forbidden You don't have permission to access this resource.

Should I change permission of home/mitacheto/projects to 755?

in flag
Have you confirmed that AppArmor is not blocking Apache from accessing your `/home` directory?
MorganFreeFarm avatar
tj flag
@matigo How could I confirmed that ?
in flag
Assuming that AppArmor is running, you'll want to check the `/etc/apparmor.d/usr.sbin.apache2` configuration file
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.