• Dear Pleskians! The Plesk Forum will be undergoing scheduled maintenance on Monday, 7th of July, at 9:00 AM UTC. The expected maintenance window is 2 hours.
    Thank you in advance for your patience and understanding on the matter.

Block Access to Domain and all web users via http

RolandE

New Pleskian
Apologies if I posted this in the wrong forum originally. :)

Hello,

I have a client who wishes to run one account on plesk purely for FTP (as network drives on Windows). The plesk web user interface is ideal for them as it makes it very easy to create ftp accounts in this way (without my involvement).

However, I need to block all http traffic to this domain and web users directories. I can't password protect them all because they will be created without my involvement. I have therefore tried to add the following to vhost.conf in the domain's conf directory:

<VirtualHost *IP address here*:80>
<Directory /var/www/vhosts/*my domain here*/httpdocs/>
Options None
AllowOverride None
Order deny,allow
Deny from all
</Directory>
</VirtualHost>

I reboot Apache and it makes no difference - whether I specify a web user's folder, the main httpdocs folder, with or without the Virtualhost tags.

I am assuming this is the way to achieve this result but I am open to suggestions. Hopefully someone can advise.

Thanks,


R.
 
What about something like

# /usr/local/psa/admin/sbin/websrvmng --add-protection --vhost-name=domain.com --directory=/var/www/vhosts/domain.com/httpdocs/
 
Hello,

Thanks for your reply, unfortunately it doesn't seem to do anything. Initially it conflicted with my vhost.conf edits. I removed those, reran the command and rebooted apache - doesn't seem to restrict access in any way.

Any more ideas?

R.
 
Could you please describe it with more details - do you need fully disabled web service (http port 80) or you want that it worked, but has been protected?
 
Hi.

I would be happy with http completely blocked on that account only. It also needs to block any web user directories (eg. www.domain.com/~mike/) by default.

All other domains on Plesk need to run normally. It's just this account where I want the customer to use the FTP facilities but with no corresponding website/web access.
 
Hi. Thanks for your help. In the end, once I'd called in the new vhost.conf as per your post, the following worked:

<Directory /var/www/vhosts/domain.com/httpdocs/>
Options None
AllowOverride None
Order deny,allow
Deny from all
</Directory>
 
Back
Top