The question is what it is that distinguishes requests for the various sites
from the perspective of IIS. If your servers have multiple IP-addresses
and your website bindings per IIS instance differ only in the
IP-address you're stuck: mkiisdir does not look at the IP-address of your
serverbindings.
But this strikes me as a very odd  configuration.

Assuming your sites are configured with different hostnames (say,
"www.brand2.com" for Site2), specifying iisserver="www.brand2.com"
will target Site2 *if only you can get nant to connect to the right
machine(s)*.
Depending on your platform configuration, this may be easier or more
difficult.

If you configure each server by running nant locally (on the machine in
question).
Adding the line "127.0.0.1 www.brand2.com" to the hosts file will
make sure you always target the instance of Site2 on the local machine
[this is also quite handy for trouble shooting].

If you you configure all servers remotely from 1 place, you could
have the nant-script edit the local hosts file before calling mkiisdir
(messy).

Alternatively, you could also give each instance of Site2 an additional
machine specific binding, e.g. "www5.brand2.com" for the instance
of Site2 on machine5, and configure your local DNS accordingly
[this is even more handy for trouble shooting, realy advisable].
Now, using each of the machine-specific hostnames will  configure Site2
on each machine.

If none of this is an option, add an attribute "machine" (or maybe even
"machines")
to the mkissdirtask.

rutger


----- Original Message ----- 
From: "Byrd, Payton" <[EMAIL PROTECTED]>
To: "'[EMAIL PROTECTED] Sourceforge. Net'"
<[email protected]>
Sent: Tuesday, 04 January, 2005 20:51
Subject: RE: [Nant-users] Error creating virtual directory!


> I don't think I was clear.
>
> On each webserver in our web farm we have multiple websites, each
> corresponding to a different NAT address.  The commonality is that each
> server uses the same name for each website within the farm, such as Site1,
> Site2, Site3, etc.  These all exist on each server in the farm.  I need
the
> ability to specify the website to install an application to via the
website
> name, not the hostname.
>
> example:
>
> <mkiisdir dirpath="c:\sources\Application1" website="Site1"
> vdirname="applications/Application1" />
>
> <mkiisdir dirpath="c:\sources\Application1" website="Site2"
> vdirname="applications/Application1" />
>
> <mkiisdir dirpath="c:\sources\Application1" website="Site3"
> vdirname="apps/DifferentApplicationName" />
>
> This is a requirement because we host a single extranet under multiple
> brands and so applications must be registered under multiple sites.  MSI
> files do not allow for this natively.  I've see a Wise installer that
allows
> you to select the website by name at runtime.  I've also deciphered how to
> do it from COM using the IISAdmin objects, and if push comes to shove I'll
> add the functionality to the <mkiisdir> task myself.
>
> Payton Byrd
> Trane eBusiness
> QED Team
> Phone: 931-905-5386
> Fax: 931-648-5901
>
> -----Original Message-----
> From: Rutger Dijkstra [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 04, 2005 12:25 PM
> To: Byrd, Payton
> Subject: Re: [Nant-users] Error creating virtual directory!
>
> yes, specify the correct hostname in the iisserver attribute
>
> rutger
>
> ----- Original Message ----- 
> From: "Byrd, Payton" <[EMAIL PROTECTED]>
> To: "'Rutger Dijkstra'" <[EMAIL PROTECTED]>
> Sent: Tuesday, 04 January, 2005 19:21
> Subject: RE: [Nant-users] Error creating virtual directory!
>
>
> > Have the IIS Dir tasks been updated to allow selecting the specific
> website?
> > We need the ability to specify the website on a multi-homed server.
> >
> > Payton Byrd
> > Trane eBusiness
> > QED Team
> > Phone: 931-905-5386
> > Fax: 931-648-5901
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On Behalf Of Rutger
> Dijkstra
> > Sent: Tuesday, January 04, 2005 12:13 PM
> > To: Andy Heyworth; [email protected]
> > Subject: Re: [Nant-users] Error creating virtual directory!
> >
> > Andy,
> >
> > in fact, if you're using RC1 of nantcontrib 0.85, then
> >
> >  <deliisdir vdirname="1557\WebClient"/>
> >  <mkiisdir dirpath="c:\inetpub\wwwroot\1557\WebClient"
> >     vdirname="1557\WebClient" />
> >
> > deletes the VS.NET generated directory configuration from
> > iis and recreates it as a virtualdir. VS.NET shouldn't notice the
> > difference.
> >
> > on another note, if you want to build an old version of your
> > project, why don't you:
> > - check out the source to a clean directory
> > - build with csc-task and such like, or
> >   build with solution-task using 'webmap' to avoid relying on
> >   iis-configuration.
> >
> > rutger
> >
> > ----- Original Message ----- 
> > From: "Andy Heyworth" <[EMAIL PROTECTED]>
> > To: "Rutger Dijkstra" <[EMAIL PROTECTED]>
> > Sent: Tuesday, 04 January, 2005 16:03
> > Subject: Re: [Nant-users] Error creating virtual directory!
> >
> >
> > > Rutger,
> > >
> > > Thank you for your informative response to my email.
> > >
> > > You said the VS.Net creates a physical directory rather than a virtual
> > > directory, is there any way in NAnt to create one, so that the
> > > solution file will open the web project created from NAnt ? I am
> > > having problems in that I cannot even delete the physical directory
> > > from NAnt created by VS.Net. The reason I am doing all of this is to
> > > get the code form SourceSafe using NAnt and setup the environment just
> > > as if VS.Net was getting the files, but VS.Net does not allow for
> > > getting labeled files!
> > >
> > > I will follow your suggestions on opening the project.
> > >
> > > Thank you so much again for your time.
> > >
> > > cheers
> > >
> > > Andy
> > >
> > >
> > > On Thu, 30 Dec 2004 13:45:31 +0100, Rutger Dijkstra
> > > <[EMAIL PROTECTED]> wrote:
> > > > mkissdir creates/reconfigures *virtual* directories only.
> > > >
> > > > VS.NET does not create a virtual directory for your project: it
> creates
> > > > a *physical* directory in your webtree and adds configuration for it
> to
> > > > IIS. In doing so, VS.NET makes it clear to IIS that the directory is
> > > > physical rather than virtual.
> > > >
> > > > If you use mkiisdir to reconfigure a project directory created by
> > > > VS.NET, mkiisdir will try to set the "path" property of  the
> directory.
> > > > IIS will reject this for a directory it knows to be physical, hence
> the
> > > > exception.
> > > >
> > > > In order to let VS.NET find your project once it is located in a
truly
> > > > virtual directory that you created yourself, you'll have to do at
> least
> > > > the following:
> > > > 1. close VS.NET if it is open.
> > > > 2. open the webinfo-file of your project in a text-editor and make
> sure
> > > >   the url it mentions for your project is correct, i.e. corresponds
> > > >   with the virtual directory you created. WARNING: this file will be
> > > >   writable even though you haven't checked it out; be sure to commit
> > > >   changes to SourceSafe.
> > > > 3. Delete your web cache (Document and Settings\<usr>\VSWebCache).
> > > >   This directory contains stale redundant information.
> > > > 4. open the project by double-clicking the PROJECT file, i.e. *proj
> and
> > > >   NOT *.sln.
> > > >   Your solution file may contain stale redundant information.
> > > >
> > > > Once you have successfully opened the project, the web cache is
> > > > recreated with up-to-date information and you can now try to open
the
> > > > solution: it might even work
> > > >
> > > > cheers, rutger
> > > >
> > > > PS. the recipe for getting to VS.NET to work with a relocated web-
> > > > project is grown from my experience. It tends to work for me but
> > > > obviously I can't promise it'll work for you. Applications that are
as
> > > > uncontrollable as VS.NET are very rare indeed.
> > > >
> > > > ----- Original Message -----
> > > > From: "Andy Heyworth" <[EMAIL PROTECTED]>
> > > > To: <[email protected]>
> > > > Sent: Wednesday, 29 December, 2004 14:32
> > > > Subject: [Nant-users] Error creating virtual directory!
> > > >
> > > > > Thnaks in advance for any information ... Andy
> > > > >
> > > > > Win2k, IIS5.0, NAnt 0.85rc1
> > > > >
> > > > > The following NAnt script segment works fine if the virtual
> directory
> > > > > was not previously created by VS.Net 2003 IDE, but fails as
follows
> if
> > > > > I have previously opened the solution from SourceSafe (which
creates
> > > > > the virtual directory).
> > > > >
> > > > > Error creating virtual directory '1557\WebClient' on
'localhost:80'.
> > > > >     Exception from HRESULT: 0x80005006.
> > > > >
> > > > >   <mkiisdir dirpath="c:\inetpub\wwwroot\1557\WebClient"
> > > > > vdirname="1557\WebClient" />
> > > > >
> > > > > On the same issue, if I successfully create the Vdir using NAnt,
> > > > > VS.Net 2003 IDE is not able to find the project file at the
created
> > > > > Vdir even though I copy all the required files as part of the
> script,
> > > > > any ideas on this one? I noticed that the Vdir created by VS.Net
> 2003
> > > > > IDE and the NAnt are not the same!
> > > > >
> > > > >
> > > >
> > >
> > >
> >
> >
> >
> > -------------------------------------------------------
> > The SF.Net email is sponsored by: Beat the post-holiday blues
> > Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
> > It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
> > _______________________________________________
> > Nant-users mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/nant-users
> >
>
>
> --------------------------------------------------------------------------
--
> ----
>
>
> Incoming mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.825 / Virus Database: 563 - Release Date: 2004-12-30
>



-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
Nant-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to