Re: Why can't I move the document root for a site in Apache 2? [SOLVED]
- To: debian-user@lists.debian.org
- Subject: Re: Why can't I move the document root for a site in Apache 2? [SOLVED]
- From: mick crane <mick.crane@gmail.com>
- Date: Tue, 01 Sep 2020 06:45:49 +0100
- Message-id: <[🔎] fd435866e2aba9213dd6d0b09c3170d3@gmail.com>
- Reply-to: mick.crane@gmail.com
- In-reply-to: <30ea29c0-7ed6-6440-bc88-8f3d874c869b@extremeground.com>
- References: <fb06c553-d677-226f-cae0-d3be65756302@extremeground.com> <09b51982-7075-485a-1fe8-ae8f1ecf7c88@mail.com> <a1c6f6fe-0b86-c4d2-4648-3f9c62c415d4@mail.com> <b878d098-ccc5-4603-d331-30d4fa1831d6@extremeground.com> <d1fa2d87-776c-8be9-ae1b-5f249a45ed11@extremeground.com> <30ea29c0-7ed6-6440-bc88-8f3d874c869b@extremeground.com>
On 2020-08-31 21:57, Gary Dale wrote:
<snipped>
Just to be clear, the folder I had to change permissions on is the
<folder containing all the web sites. This is many levels above the
document root,
I think the document root is just where apache2 looks first.
*Don't know if you are supposed to do it like that* but think the actual
html files can be anywhere so long as they have the right permissions
and have a link to them in the document root.
Whenever I've changed anything I do.
#!/bin/bash
find /path_to_html_files/ -type d -exec chmod 750 {} \;
find /path_to_html_files/ -type f -exec chmod 640 {} \;
chown -R root /path_to_html_files/*;
chgrp -R www-data /path_to_html_files/*;
remembering if there is any file wants to be executable.
mick
--
Key ID 4BFEBB31
Reply to: