Gentoo Archives: gentoo-dev

From: Stuart Herbert <stuart@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] RFC - apache start page.
Date: Tue, 25 May 2004 17:48:46
Message-Id: 200405251848.41428.stuart@gentoo.org
In Reply to: Re: [gentoo-dev] RFC - apache start page. by Stroller
1 On Tuesday 25 May 2004 10:29, Stroller wrote:
2 > Well, this may simply be because I've upgraded from a previous
3 > installation of Apache2, or it may be because I didn't see the ewarn
4 > when I emerged, but I used to have a /home/www/htdocs/ directory in
5 > which everything installed. I believe that cgi-bin, icons & error were
6 > in there..?
7
8 Gentoo used to use /home/htdocs as the ServerRoot for Apache. It was moved
9 to /var/www/localhost round about the release of apache-2.0.48-r1.
10
11 IIRC, the move happened without much warning because we had to release -r1 to
12 address a security problem. It just happened that -r1 used the proposed
13 defaults, and we had to get the fix out quickly.
14
15 > Now I find that I have separate /var/www/htdocs/ & /var/www/localhost
16 > directories and that cgi-bin, icons & error go in the top-level
17 > /var/www/.
18
19 Apache should be installing this arrangement:
20
21 /var/www/localhost
22 |- htdocs
23 |- cgi-bin
24 |- icons
25 |- error
26
27 This is so that you can create new virtual hosts under /var/www.
28
29 > GLEP 11 is presumably not intended as user-documentation, so
30 > an explanation for someone who finds GLEP 11 heavy-going would be
31 > appreciated.
32
33 I have asked for help from the gentoo-doc project; unfortunately, no-one has
34 been able to volunteer their time to help us with docs.
35
36 David Stanek has been kind enough to start work on this. You can find a draft
37 at:
38
39 http://roninds.homelinux.net/vhost.html
40
41 We really need help from people who can spare the time to help us write some
42 good docs. Otherwise, you'll have to wait until they're top of my priority
43 list, and then I'll write them myself ;-)
44
45 This information was posted to the gentoo-web-user@g.o mailing list back in
46 April.
47
48 > My server is never addressed as "localhost".
49
50 Doesn't matter. If we're going to make it possible for you to install
51 web-based apps using Portage, they have to have a default home. That's
52 what /var/www/localhost is.
53
54 > I do use virtuals,
55 > although I'd be happy to admit I don't have a clue about them. I
56 > believe that when I originally emerged Apache2 I made suitable
57 > directories for compaq.stroller.uk.eu.org & www.stroller.uk.eu.org
58 > within htdocs & pointed the virtual hosting at those directories. When
59 > squirrelmail emerged to htdocs I could simply symlink
60 > mail.stroller.uk.eu.org to squirrelmail in the same directory. Now
61 > compaq.stroller.uk.eu.org & www.stroller.uk.eu.org reside within the
62 > /var/www/ alongside localhost
63
64 You can still symlink if you wish. Nothing we've changed prevents you from
65 doing so.
66
67 > In writing this email to you I find that an emerge --update has placed
68 > the new squirrelmail in /var/www/htdocs/, a directory which is now
69 > otherwise fairly redundant, as it only contains the default Apache
70 > start-page (in several languages). That update to squirrelmail has been
71 > ignored the past month, as I wasn't aware it would go there.
72
73 Okay, sounds like you're running with ACCEPT_KEYWORDS=~x86. It also sounds
74 like your /etc/vhosts/webapp-config file is incorrect too.
75
76 I recommend that you run
77
78 emerge -C squirrelmail
79 emerge webapp-config
80 etc-update
81 emerge squirrelmail
82
83 to restore your system to something approaching sanity.
84
85 I'd also recommend that you either pay closer attention to what and where
86 Portage installs things, or that you stop running with ACCEPT_KEYWORDS=~x86.
87
88 > This is what _I_ find confusing, however it was you that stated:
89 > > I'd say that the main problem people have (apart from my stupid bugs
90 > > ;-)
91 > > is that they just don't h.a.f.c. about virtual hosting.
92
93 Actually, it wasn't Chuck who said that, it was me.
94
95 > In what other ways have users demonstrated to you that the don't have a
96 > clue about virtual hosting..?
97
98 This is based on my personal experience of directly talking to Gentoo users
99 about web-based applications over the last month or two. Most users are
100 comfortable w/ using their box to serve pages for just the one domain; moving
101 to using name-based virtual servers has demonstrated that there's a bit more
102 to read about.
103
104 There are good docs already available from Apache's website, explaining how
105 virtual hosting works. We just need some help to write some Gentoo-specific
106 ones - especially ones that show you how much easier it is to do on Gentoo
107 than on <insert alternative Linux distribution here>.
108
109 Advance warning: when I can make the time, I plan to look at the idea of
110 installing Apache with virtual hosting ON by default.
111
112 Hope that helps,
113 Stu
114 --
115 Stuart Herbert stuart@g.o
116 Gentoo Developer http://www.gentoo.org/
117 http://stu.gnqs.org/diary/
118
119 GnuPG key id# F9AFC57C available from http://pgp.mit.edu
120 Key fingerprint = 31FB 50D4 1F88 E227 F319 C549 0C2F 80BA F9AF C57C
121 --

Replies

Subject Author
Re: [gentoo-dev] RFC - apache start page. Stroller <stroller@××××××××××××××××××.uk>