Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm a bit scared to ask this because I got so many negative votes for simply asking a question last time, but here goes;

Where in the Linux (Ubuntu) directory structure is it 'normal' to put public and private website files.

Say I have a server and I want directories;

mysite1.co.uk/
mysite1.co.uk/www/
mysite2.co.uk
mysite2.co.uk/www/

where would they normally be put?

Update: I'm using Nginx (not Apache).

share|improve this question
    
This is probably because this is a too basic question which indicates that you didn't read any documentation, HOWTO or just googled. –  mailq Aug 9 '11 at 19:43
3  
I have seen /var/www/fqdn and /srv/www/fqdn on various systems. –  Zoredache Aug 9 '11 at 19:53
    
    
2  
Have a +1 for having the balls to ask a fair question on what can be intimidating site! But like others have said, it doesn't matter where you place the files, it can boil down to personal preference. –  Coops Aug 9 '11 at 20:15
show 1 more comment

2 Answers

up vote 4 down vote accepted

Under /var/www. But this is not a convention you have t follow. You can put them wherever you want, as long as Apache has access to it.

share|improve this answer
    
Thanks. Actually I'm using Nginx not Apache. Does that change your recommendation? –  Nigel Alderton Aug 9 '11 at 19:52
    
no. Doesn't change anything. –  mailq Aug 9 '11 at 19:54
    
Ok, thanks again. –  Nigel Alderton Aug 9 '11 at 20:11
add comment

I use

/var/vhosts/domain.name/html
/var/vhosts/domain.name/logs

but /var/vhosts is a symlink to /srv/vhosts in my case. I had my cake and ate it.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.