Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

IIS7 Setup

Engaged ,
Jun 08, 2011 Jun 08, 2011

Morning,
We are migrating from IIS6 to IIS7 and have the following issue:-
We have multiple sites set up in IIS pointing at the same code base as we do this to accommodate scale and multi-language applications. Now in IIS6 this is no problem, however in IIS7 when you set up the handlers to connect ColdFusion it creates a web.config with the handlers in it in the webroot. Now I need these to be different for each site and so the single code base is now a big problem.
I cannot be the first person to have this problem and it is not limited to ColdFusion but to the approach. Is there a way to push these settings out of the web.config and into ApplicationHost.config for example?
Thanks.


Simon

2.3K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 08, 2011 Jun 08, 2011

I think it just depends on where you make the changes in IIS when using the admin console.  If you make the changes at your website level in the console then those changes are written to the web.config file in the root directory.  If you make your changes at the server level in the console then those changes are written to the applicationhost.config file.  Of course, you can make the changes manually to those files as well (carefully).

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 08, 2011 Jun 08, 2011

Miguel,

Thanks for your answer, I think I should have been clearer. I have several ColdFusion instances and I want multiple versions of my site each attached to a different CF instance. The code does not differ at all, only that each web site needs to be attached to a different ColdFusion instance.

To attach IIS website to ColdFusion you add the following to web.config:-

<?xml version="1.0" encoding="UTF-8"?> <configuration>     <system.webServer>         <staticContent>             <mimeMap fileExtension=".air" mimeType="application/vnd.adobe.air-application-installer-package zip" />         </staticContent>         <handlers>             <add name="JWildCardHandler" path="*" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\2\jrun_iis6_wildcard.dll" resourceType="Unspecified" requireAccess="None" preCondition="bitness64" />             <add name="hbmxmlHandler" path="*.hbmxml" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="cfswfHandler" path="*.cfswf" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="cfrHandler" path="*.cfr" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="cfcHandler" path="*.cfc" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="cfmlHandler" path="*.cfml" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="cfmHandler" path="*.cfm" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="jwsHandler" path="*.jws" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />             <add name="jspHandler" path="*.jsp" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\jrun_iis6.dll" resourceType="Either" responseBufferLimit="0" />         </handlers>         <defaultDocument>             <files>                 <add value="index.cfm" />             </files>         </defaultDocument>     </system.webServer> </configuration>

Now only the JWildCardHandler needs to differ from site to site, but I cannot find a way to have mutliple websites pointing at the same codebase and connect them to different CF instances on IIS7

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 08, 2011 Jun 08, 2011

I'm not sure if I can help but maybe some clarification will help others understand your issue.

You want one web site connected to multiple ColdFusion instances? The opposite of multi-homing (connecting multiple web sites to a single ColdFusion instance)?

http://help.adobe.com/en_US/ColdFusion/9.0/Admin/WSc3ff6d0ea77859461172e0811cbf363a5d-7fef.html

OR

You said you have multiple web sites and multiple ColdFusion instances.  Do you want each web site to use it's own ColdFusion instance?  For this case you need to run the web server configuration utility for each web site that you have and select the appropriate ColdFusion instance for each (you can't select the ALL IIS web sites option).

http://help.adobe.com/en_US/ColdFusion/9.0/Admin/WSc3ff6d0ea77859461172e0811cbf364104-7fc4.html

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 08, 2011 Jun 08, 2011

Ok sorry here is what I am trying to do.

I have 6 instances on one server which all run the same web site and the traffic is handled by a hardware load balancer. So they are identical in IIS apart from the port they run on. So in IIS 6 we would point them at the same code base. For the problems stated above this is not as straightforward on IIS7.

I hope that is clearer.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 08, 2011 Jun 08, 2011

Ok, I think I am starting to follow you.  So this is more of IIS settings than ColdFusion really.  How did you set this up in IIS6?  If you can tell me that then I might be able to direct you in IIS7.  I am by no means an IIS expert but I have been working with it quite a bit lately.

I think you can do what you are saying with the Bindings... option in IIS7.  Click on you web site in IIS Manager.  You should have a "Bindings..." option over on the right in the Actions pane.  From there you can assign things like the port number, ip address, and host headers.  Is that what you are looking for?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 09, 2011 Jun 09, 2011
LATEST

I have resolved it you need to put the following into your ApplicationHost.config:-

<location path="my.site.com">      <system.webServer>           <handlers>                <add name="JWildCardHandler" path="*" verb="*" modules="IsapiModule" scriptProcessor="R:\servers\JRun4\lib\wsconfig\2\\jrun_iis6_wildcard.dll" resourceType="Unspecified" requireAccess="None" preCondition="bitness64" />
          </handlers>      </system.webServer> </location>

Bare in mind that from this point onward you cannot edit this value from within the interface, as it tries to override it with the web.config and that gets you right back to square one.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources