Re: [OT] Doubt on directories for development

2002-04-22 Thread Perrin Harkins

F. Xavier Noria wrote:
 The fact is that developers in my team have Apache under /usr/local in
 Linux machines, but we would prefer to develop as normal users, not as
 www or nobody, though that will be the user in production.
 
 What is the standard way to configure things for that? We have created
 somehow the Apache directory layout under the root of the project tree
 and call httpd -f project_root/conf/httpd.conf, where we customize the
 user and group (in my case fxn), full paths to log and pid files
 writable by that user, etc. but ServerRoot is /usr/local/apache and the
 original modules under /usr/local/apache are there, so we cannot use
 $r-server_root_relative to access, say, to application config files
 which seems to be standard (and quite natural) idiom. The httpd.conf in
 CVS is a template customized once per-machine with a script.

It doesn't seem worth it to me to go to a lot of trouble to avoid 
starting apache as root in development, especially if that's how you'll 
do it in production.  I've always just put my modules in 
/usr/local/apache/lib/perl where they get picked up automatically (with 
no use lib or INC changes).  I make that directory writeable by my 
standard login (a security hole, but it's just my personal machine and 
not visible on the Internet), and keep a root shell open for restarting 
the server.  That works fine unless you have mutiple users developing on 
the same box.

- Perrin




Re: [OT] Doubt on directories for development

2002-04-22 Thread lembark


 The fact is that developers in my team have Apache under /usr/local in
 Linux machines, but we would prefer to develop as normal users, not as
 www or nobody, though that will be the user in production.

See the section on configuring Apache using Perl sections
in the eagle book. I normally use the approach of having each
user's .*profile export APACHE_PORT and using $Port = $ENV{APACHE_PORT}
or croak $$: Environment missing APACHE_PORT; for the user's
config files. Using the nobody approach works well enough,
but the separate ports allow developers to have their own server
on a high-numbered port w/o stepping on one another.

--
Steven Lembark  2930 W. Palmer
Workhorse Computing  Chicago, IL 60647
   +1 800 762 1582



Re: [OT] Doubt on directories for development

2002-04-22 Thread darren chamberlain

* [EMAIL PROTECTED] [EMAIL PROTECTED] [2002-04-22 09:53]:
  The fact is that developers in my team have Apache under /usr/local in
  Linux machines, but we would prefer to develop as normal users, not as
  www or nobody, though that will be the user in production.
 
 See the section on configuring Apache using Perl sections in the
 eagle book. I normally use the approach of having each user's
 .*profile export APACHE_PORT and using $Port = $ENV{APACHE_PORT} or
 croak $$: Environment missing APACHE_PORT; for the user's config
 files. Using the nobody approach works well enough, but the separate
 ports allow developers to have their own server on a high-numbered
 port w/o stepping on one another.

I like using something like the user's UID as the port on which to start
Apache; with bash, at least, UID is automatically set.  If not,
something like:

  : ${UID:=`id | sed -e 's/uid=\([0-9]*\)(.*/\1/'`}

in .profile will set it for the Bourne shell (don't know/care about csh).

(darren)

-- 
Men never do evil so completely and cheerfully as when they do it
from religious conviction.
-- Blaise Pascal



[OT] Doubt on directories for development

2002-04-21 Thread F . Xavier Noria

I am working in my first mod_perl real-life project, I would like to ask
you for a directory layout for development.

The fact is that developers in my team have Apache under /usr/local in
Linux machines, but we would prefer to develop as normal users, not as
www or nobody, though that will be the user in production.

What is the standard way to configure things for that? We have created
somehow the Apache directory layout under the root of the project tree
and call httpd -f project_root/conf/httpd.conf, where we customize the
user and group (in my case fxn), full paths to log and pid files
writable but that user, etc. but ServerRoot is /usr/local/apache and the
original modules under /usr/local/apache are there, so we cannot use
$r-server_root_relative to access, say, to application config files
which seems to be standard (and quite natural) idiom. The httpd.conf in
CVS is a template customized once per-machine with a script.

I would appreciate any hint very much, we could begin right with a good
layout next Monday.

Thank you very much!

-- fxn




Re: [OT] Doubt on directories for development

2002-04-21 Thread Ask Bjoern Hansen

On Sat, 20 Apr 2002, F. Xavier Noria wrote:

 I am working in my first mod_perl real-life project, I would like to ask
 you for a directory layout for development.

 The fact is that developers in my team have Apache under /usr/local in
 Linux machines, but we would prefer to develop as normal users, not as
 www or nobody, though that will be the user in production.

 What is the standard way to configure things for that?

I usually just setup an httpd.conf (and apachectl) for the user and
then use mod_proxy to forward requests for the virtualhost to
whatever high port the user is using.

The serverroot is set to be /home/user/apache and the libexec
directory symlinked from /usr/local/apache/libexec (or wherever the
system apache is installed).


 - ask

-- 
ask bjoern hansen, http://ask.netcetera.dk/   !try; do();





[OT] Doubt on directories for development

2002-04-20 Thread F . Xavier Noria

I am working in my first mod_perl real-life project, I would like to ask
you for a directory layout for development.

The fact is that developers in my team have Apache under /usr/local in
Linux machines, but we would prefer to develop as normal users, not as
www or nobody, though that will be the user in production.

What is the standard way to configure things for that? We have created
somehow the Apache directory layout under the root of the project tree
and call httpd -f project_root/conf/httpd.conf, where we customize the
user and group (in my case fxn), full paths to log and pid files
writable by that user, etc. but ServerRoot is /usr/local/apache and the
original modules under /usr/local/apache are there, so we cannot use
$r-server_root_relative to access, say, to application config files
which seems to be standard (and quite natural) idiom. The httpd.conf in
CVS is a template customized once per-machine with a script.

I would appreciate any hint very much, we could begin right with a good
layout next Monday.

Thank you very much!

-- fxn