John, My appologies; I sometimes forget which of the features I use are WiX cannon and which I have added / augmented.
On a positive note, I think I have worked all of the bugs out of my (based upon code by Cody Cutrer) PermissionEx changes. I should be able to submit them next week. Thanks, Thomas S. Trias Senior Developer Artizan Internet Services http://www.artizan.com/ -------- Original Message -------- Subject: Re: [WiX-users] IIS virtual web directory modification/settings From: John Trump <john_tr...@symantec.com> To: tomtr...@artizan.com, General discussion for Windows Installer XML toolset. <wix-users@lists.sourceforge.net> Date: 4/16/2009 3:33 PM > Thanks Tom. > > I have implemented #1 with no problem, but #2 is giving me some build > errors. > > First it would not recognize the following as part of the PermissionEx > schema: > > Type="allow" ApplyToSelf="yes" ApplyToSubfolders="yes" ApplyToFiles="no > > So, I took those out, but now I get this error: > > error LGHT0130 : The primary key > 'INSTALLDIR.0781BB0D_8666_4D92_9BC2_7C15FBCAA7B6/CreateFolder/[ComputerN > ame]/ASPNET' is duplicated in table 'SecureObjects'. Please remove one > of the entries or rename a part of the primary key to avoid the > collision. > > Here is how I have set it up: > > <Directory Id="TARGETDIR" Name="SourceDir"> > <Directory Id="INSTALLDIR"> > <Component Id="BERetrieveWebSite" > Guid="A2FDDF48-31B5-40D1-A738-366AB9E935E6"> > <CreateFolder> > <util:PermissionEx User="ASPNET" Domain="[ComputerName]" > Read="yes" ReadAttributes="yes" > ReadExtendedAttributes="yes" > ReadPermission="yes" Synchronize="yes" Traverse="yes"/> > <util:PermissionEx User="ASPNET" Domain="[ComputerName]" > Read="yes" ReadAttributes="yes" > ReadExtendedAttributes="yes" ReadPermission="yes" > Synchronize="yes"/> > </CreateFolder> > > John > > -----Original Message----- > From: Thomas S. Trias [mailto:tomtr...@artizan.com] > Sent: Tuesday, April 14, 2009 5:25 PM > To: General discussion for Windows Installer XML toolset. > Subject: Re: [WiX-users] IIS virtual web directory modification/settings > > 1. I ended up calling aspnet_regiis from a custom action (if there is a > better way, someone speak up): > > <PropertyRef Id="NETFRAMEWORK20INSTALLROOTDIR"/> > > <!-- Ideally we would use -r with a metabase path, but we would need > > some way of getting that information; maybe add that step as an addition > > to the IIS extension --> > <CustomAction Id="SetAspNet20_Cmd" Property="SetAspNet20" > Value=""[NETFRAMEWORK20INSTALLROOTDIR]aspnet_regiis.exe" -ir > -enable"/> > > <CustomAction Id="SetAspNet20" BinaryKey="WixCA" > DllEntry="CAQuietExec" Execute="deferred" Return="check"/> > > <InstallExecuteSequence> > <Custom Action="SetAspNet20_Cmd" Before="CostFinalize">NOT > (SKIPCONFIGUREIIS OR Installed) AND VersionNT > 400</Custom> > <Custom Action="SetAspNet20" Before="ConfigureIIs">NOT > (SKIPCONFIGUREIIS OR Installed) AND VersionNT > 400</Custom> > </InstallExecuteSequence> > > Note that I set the script maps by hand using WiX akin to the following: > > <iis:WebApplicationExtension Extension="aspx" > Executable="[NETFRAMEWORK20INSTALLROOTDIR]aspnet_isapi.dll" > Verbs="GET,HEAD,POST" CheckPath="no" Script="yes"/> > > Note that the NETFRAMEWORK20INSTALLROOTDIR property requires the Wix > NetFx Extension; you can search for it yourself, but why? :-) > > 2. I used util:PermissionEx elements as a child of a CreateFolder > element associated with the target of the virtual directory: > > <util:PermissionEx User="ASPNET" Domain="[ComputerName]" > Type="allow" ApplyToSelf="yes" ApplyToSubfolders="yes" ApplyToFiles="no" > > Read="yes" ReadAttributes="yes" ReadExtendedAttributes="yes" > ReadPermission="yes" Synchronize="yes" Traverse="yes"/> > <util:PermissionEx User="ASPNET" Domain="[ComputerName]" > Type="allow" ApplyToSelf="yes" ApplyToSubfolders="yes" > ApplyToFiles="yes" Read="yes" ReadAttributes="yes" > ReadExtendedAttributes="yes" ReadPermission="yes" Synchronize="yes"/> > > That snippet gives ".\ASPNET" Read and Traverse Folder privileges. At > some point, I may add an improvement to handle that with a single > element (and thus differentiate Traverse and Execute depending upon > ApplyToFiles). > > Note that it is much safer to use [ComputerName] instead of leaving out > the Domain attribute entirely (except for well known accounts) or "."; > things may work on XP / 2K, but then fail on Vista / 2K3. > > 3. Use iis:WebDirProperties: > > <iis:WebDirProperties Id="<Id>" > DefaultDocuments="myproductsname.aspx"/> > > Unfortunately, I couldn't find any reference to MD_DIRECTORY_BROWSING > (which is a set of flags that controls the "Enable Default Document" > setting, along with various aspects of directory browsing); you should > look for a feature request in the issue tracker and add it if it is not > there. Hopefully, someone else or I will get to it in the near future. > > I noticed that a setting of "-" will clear the default documents > (undocumented); it also looks like the default documents will get set > (the code does not append them to any existing default documents), so > you should have full control over the ordering. > > Thanks, > > Thomas S. Trias > Senior Developer > Artizan Internet Services > http://www.artizan.com/ > > > > -------- Original Message -------- > Subject: [WiX-users] IIS virtual web directory modification/settings > From: John Trump <john_tr...@symantec.com> > To: <wix-users@lists.sourceforge.net> > Date: 4/14/2009 2:28 PM > >> I need to accomplish the following install tasks using WiX: >> >> >> >> 1. Set ASP.NET version to 2.0.50727 >> >> >> >> 2. Set security for virtual web directory >> >> a. Add the following users: >> >> i. <MachineName>\ASPNET (for example MyServer\ASPNET) >> >> ii. <MachineName>\IIS_WPG (for example MyServer\IIS_WPG) >> >> >> >> 3. Set default content page >> >> a. "Enable default content page" >> >> b. set to <myproductsname>.aspx >> >> c. In the list of pages, it needs to be the top entry. >> >> >> >> Any ideas would be appreciated. >> >> >> >> Thanks, >> >> >> >> John Trump >> >> >> >> >> >> > > > > > > > ------------------------------------------------------------------------------ Stay on top of everything new and different, both inside and around Java (TM) technology - register by April 22, and save $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. 300 plus technical and hands-on sessions. Register today. Use priority code J9JMT32. http://p.sf.net/sfu/p _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users