welcome: please sign in

Upload page content

You can upload content for the page named below. If you change the page name, you can also upload content for another page. If the page name is empty, we derive the page name from the file name.

File to load page content from
Page name
Comment
Last name of the current Debian Project Leader

Revision 2 as of 2008-05-25 13:31:08

Edit

RunningYourOwnApache

This page describes how to run your own apache HTTP daemon, for example if you have special needs regarding apache modules etc.

TableOfContents

I have an apache instance with mod_python running for http://www.siebengang.net/ .

1. Apache setup and startup

Get a working apache/mod_python installation (in your home dir), and set up a startup procedure, so that cron starts your daemon when mire reboots. Take a cron job like

@reboot   run-in-pagsh --fg ~/apache2/bin/apachectl start

as a starting point.

1.1. Port issues

Your httpd must be configured so that it listens on a dedicated port. The standard port 80 won't work.

We currently have no restriction on which users can listen on which ports above 1024, but we plan to implement a firewall soon, similar to what we had on our old server fyodor. So please submit a firewall rule request on [https://members.hcoop.net/portal/sec the portal's security settings page], so that when we enable the firewall and binding restrictions, we know to leave the ports open for you.

I got 8880 (and 8881 for another httpd) and have this in my httpd.conf:

Listen 8880

1.2. mod_python specials

I just discovered the following lines in my httpd.conf, too. I think they are necessary for mod_python to function properly (my mod_python and some more modules are installed in ~/python/mod_python):

<IfModule mod_python.c>
    PythonPath "sys.path + ['/afs/hcoop.net/user/b/be/beni/python']"
</IfModule

2. domtool config

Next you need "port forwarding" of http requests for your domain to your own httpd (so that you don't need to use addresses like http://www.siebengang.net:8880/index.html, but http://www.siebengang.net/index.html gets "mapped" to port 8880). In the domtool setup for me this looks like

domain "siebengang.net" with
  (* NS/DNS/Mail stuff omitted *)
  web "www" with
    proxyPass "/" "http://localhost:8880/";
    proxyPassReverse "/" "http://localhost:8880/";
  end;
end;

That should be about all you need...

3. AFS problem

You may be interested in an AFS related problem I have encountered and not been able to solve yet: https://bugzilla.hcoop.net/show_bug.cgi?id=291