Re: [users@httpd] conditional listen???

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 15 Mar 2005 14:59:38 +0530, Benjamin <benjamin@xxxxxxxxxxxxx> wrote:
>  Wot is the default directory into which this IfDefine directive will look
> for the said script.
>  
>  I tried all combinations under /home/user/apache/ , /home/user/apache/conf,
> /home/user/apache/bin/ or the directory from where I call httpd.
>  the directive inside httpd.conf looks somethign like this:
>  <IfDefine IPAvailable> Listen 12.34.56.89:80 </IfDefine> Unless i specify
> the complete path in the IfDefine like : <IfDefine
> /home/user/apache/IPavailable> Listen 12.34.56.89:80 </IfDefine> and also
> along with the -D option for httpd ie. httpd -D
> /home/user/apache/IPavailable it duz not seem to work. Shud the script be
> under the ServerRoot , which is /home/user/apache/ for me. 

I think you are a little confused.

You need to write a script that checks to see whether the IP address
is available.  Then at the end of this script, you start apache as
follows (using pseudo-code):

if the IP address is available
  apachectl -D IPavailable
else
  apachectl
end

The <IfDefine IPavailable> block does not run a script.  It simply
checks to see whether a particular variable (IPavailable) was passed
on the command line when apache was started.  It is your
responsibility to pass that variable conditional on the availability
of the IP address.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux