From: gopher-project-bounces+rachael=telefisk.org@lists.alioth.debian.org Date: Fri Sep 16 22:21:41 2011 Subject: Re: [gopher] Gophernicus 1.2-beta & virtual hosting Hi Kim, I have read this yesterday (thanks!) but wished to play more with the server before responding. Op 15-09-11 15:58, Kim Holviala schreef: > On 14.9.2011 17:10, Walter Vermeir wrote: > >>> "The primary vhost directory (set with the -h<HOSTNAME> option) >>> must exist >>> or virtualhosting will be disabled." >> >> What hostname? I understood it as the hostname of the server, not the >> domainname > > FQDN, as in the hostname your users will use to come in. Again, badly > written documentation... > Well, I had it understood as a FQDN and also configured it so. But when something does not work like you wish it to work you start looking at a reason. And I got the idea, maybe I have understood hostname here wrongly as a domainname. But regarding documentation, the part about the command line options, I did figured it out, but some practical examples would be useful there also. But.... that is a good idea for my new gophersite .... about how to setup a gophersite, my experiences and advice. So with the settng in xinetd at -hvermeir.dyndns.org I created the >> directory /var/gopher/vermeir.dyndns.org >> >> The only result was that vermeir.dyndns.org did serv directly from >> that new directory but also gopher.wikizine.org > > OK, now we're talking, it's actually working. > > Gopher the protocol doesn't have virtual hosting. What Gophernicus > does is fake vhosting, the kind we used to do in HTTP in ~1997 before > HTTP/1.1 and it's fancy Host: header came along. > > The way it works is simple: if a user has visited any virtual domain > before that's where he'll stay. If not, he'll get the default virtual > host menu (in your case /var/gopher/vermeir.dyndns.org). The trick is > to have a generic "directory" page in your default virtual host > gophermap. That way a new user can select the vhost he wants to be in. > > Also, if content only exists in one vhost then the user is redirected > there. > > Example: > > gopher://holviala.com/1/~kim/ > gopher://gophernicus.org/1/software/ > > Both resolve to the same IP and are just vhosts in a single server. > Browse around my comics collection and you'll stay under holviala.com, > and do the same for gopher software and you'll stay in > gophernicus.org. However, if you'll wait for your session to expire > (or are simply a new user) AND open up the root selector then you'll > *always* land into the same root menu (as the system doesn't know > where you want to be). The way I solved that was to simply remove the > holviala.com root and combine them into the same gophernicus.org root. This explains a lot. It seems that I had an different definition of the concept "virtual hosting". Then it is logical "that it does not work". I will (at least for now) not use this virtual hosting. A gopher link is still a URL. I find it very important that a url always point to the same spot. In any case, that makes things more simpler, and that is where it is all about with gopher, keeping it simple. > > =/home/kim/shared/code/gophernicus/server/examples/counter/counter.sh > "We're not counting, but you're visitor number " "." > > > > > - Kim > I have found at your gophersite stats scripts but .... found it! gopher://holviala.com/1/~kim/code/gophernicus/server/examples/counter/ I like your visitor counter ;) Thanks for all the help and especialy for making Gophernicus. Walter _______________________________________________ Gopher-Project mailing list Gopher-Project@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/gopher-project Thread start (DIR) [gopher] Gophernicus 1.2-beta & virtual hosting (DIR) Followup: Re: [gopher] Gophernicus 1.2-beta & virtual hosting (DIR) Followup: Re: [gopher] Gophernicus 1.2-beta & virtual hosting