New Template Installed to Old Template Location

Repository of web frameworks and applications for Microsoft IIS.
User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

New Template Installed to Old Template Location

20 Aug 2014, 13:04

Good morning!

I am getting an unexpected result when adding a new Railo 4 Tomcat project.

It appears that the installer ignores the physical path and points to C:\railo4\tomcat\webapps\ROOT\.

If I rename \website folder name\index.cfm to index.cfm.old, I get the expected 403 message. However, that copy of Index.cfm is not served.

If I rename C:\railo4\tomcat\webapps\ROOT\ to index.cfm.old, I get a 404 error.

On another machine, each installed instance of the Railo 4 Tomcat project is independent of the others.

I've added the appropriate HOST section to server.xml. but haven't been able to find any further docs on selecting a different web root.

Here are a couple of screen shots. The first shows the options I used setting up a site (I tried the process with several variations). Please note that "domainname" isn't what I actually entered, I just didn't want to list the domain in a screen shot.

The second shows an overwrite warning that I do not get on the other machine I mentioned earlier.

first.png
First Screen Shot, Options Selected
first.png (90.93 KiB) Viewed 8416 times



second.png
Second Screen Shot, Warning Message
second.png (40.23 KiB) Viewed 8416 times

User avatar
Posts: 110
Joined: 07 Mar 2012, 10:22

Re: New Template Installed to Old Template Location

21 Aug 2014, 05:19

Hello,

1. To deploy new Railo site in IIS with Helicon Zoo is not necessary to use Railo template.
You can just copy web.config file to new location. It contains <heliconZoo> and <handlers> sections with essential configuration.

2. You do not need to create Host sections in server.xml. Railo Tomcat server powered by HeliconZooTomcatValve module.
When Tomcat gets request from IIS, this module creates web site in tomcat configuration in runtime.

User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

Re: New Template Installed to Old Template Location

21 Aug 2014, 07:35

Thank you for the clarification!

Can you tell me what setting needs to be changed to point to the correct root folder?

User avatar
Posts: 110
Joined: 07 Mar 2012, 10:22

Re: New Template Installed to Old Template Location

21 Aug 2014, 10:24

No specific changes in web.config needed to change root folder.
You can change the site root folder in IIS Manager. Select site, click 'Basic Settings...' and select new physical path.

User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

Re: New Template Installed to Old Template Location

21 Aug 2014, 12:05

This is not working properly for me. Could you review my initial post, please?

User avatar
Posts: 110
Joined: 07 Mar 2012, 10:22

Re: New Template Installed to Old Template Location

22 Aug 2014, 05:47

Hello,

It appears that the installer ignores the physical path and points to C:\railo4\tomcat\webapps\ROOT\.


Yes, the installer ignores this path. You need to create regualar site in IIS.

If I rename \website folder name\index.cfm to index.cfm.old, I get the expected 403 message.


Why you rename this file? Please describe.

You do not need touch tomcat config or webapps folder. Just create IIS web site, place to the site your application files and create (or copy) web.config:

Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <system.webServer>
    <heliconZoo>
      <clear />
      <application name="railo.4.project">
        <environmentVariables>
          <add name="ERROR_LOG_DIR" value="%APPL_PHYSICAL_PATH%/logs" />
        </environmentVariables>
      </application>
     </heliconZoo>
    <handlers>
      <remove name="railo.4.project#x86.cfm"   />
      <remove name="railo.4.project#x86.cfc"   />
      <remove name="railo.4.project#x86.cfml"  />
      <remove name="railo.4.project#x86.cfr"   />
      <remove name="railo.4.project#x86.cfswf" />
     
      <remove name="railo.4.project#x64.cfm"   />
      <remove name="railo.4.project#x64.cfc"   />
      <remove name="railo.4.project#x64.cfml"  />
      <remove name="railo.4.project#x64.cfr"   />
      <remove name="railo.4.project#x64.cfswf" />



      <add name="railo.4.project#x86.cfm"   scriptProcessor="railo.4.tomcat" path="*.cfm"   verb="*" modules="HeliconZoo_x86" preCondition="bitness32" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x86.cfc"   scriptProcessor="railo.4.tomcat" path="*.cfc"   verb="*" modules="HeliconZoo_x86" preCondition="bitness32" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x86.cfml"  scriptProcessor="railo.4.tomcat" path="*.cfml"  verb="*" modules="HeliconZoo_x86" preCondition="bitness32" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x86.cfr"   scriptProcessor="railo.4.tomcat" path="*.cfr"   verb="*" modules="HeliconZoo_x86" preCondition="bitness32" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x86.cfswf" scriptProcessor="railo.4.tomcat" path="*.cfswf" verb="*" modules="HeliconZoo_x86" preCondition="bitness32" resourceType="Unspecified" requireAccess="Script" />
     
      <add name="railo.4.project#x64.cfm"   scriptProcessor="railo.4.tomcat" path="*.cfm"   verb="*" modules="HeliconZoo_x64" preCondition="bitness64" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x64.cfc"   scriptProcessor="railo.4.tomcat" path="*.cfc"   verb="*" modules="HeliconZoo_x64" preCondition="bitness64" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x64.cfml"  scriptProcessor="railo.4.tomcat" path="*.cfml"  verb="*" modules="HeliconZoo_x64" preCondition="bitness64" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x64.cfr"   scriptProcessor="railo.4.tomcat" path="*.cfr"   verb="*" modules="HeliconZoo_x64" preCondition="bitness64" resourceType="Unspecified" requireAccess="Script" />
      <add name="railo.4.project#x64.cfswf" scriptProcessor="railo.4.tomcat" path="*.cfswf" verb="*" modules="HeliconZoo_x64" preCondition="bitness64" resourceType="Unspecified" requireAccess="Script" />
    </handlers>
    <defaultDocument>
      <files>
        <remove value="index.cfm" />
        <add value="index.cfm" />
      </files>
    </defaultDocument>
  </system.webServer>
</configuration>


This is all you need.

User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

Re: New Template Installed to Old Template Location

22 Aug 2014, 08:47

I created a regular site in IIS, copied in web.config and put in an Index.cfm file.

When I view the site in a browser, it shows the same index page as the other railo site - it ignores the files in the new website's directory.

User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

Re: New Template Installed to Old Template Location

24 Aug 2014, 21:17

Good evening, Ruslan.

I would still like assistance with my problem.

To summarize my most recent troubleshooting steps:

Added cb.domainname.com to my DNS server, pointing to the server running Railo 4 Tomcat project.

I copied web.config (created using your post below) to the C:\Hosted\cdDemo folder.

I added a logs folder to the C:\Hosted\cdDemo folder.

In the C:\Hosted\cdDemo folder, I created an index.cfm file that contains the following code:

<cfloop list="application,session,variables,client,url,form,request,server,cgi"
index="i">
<cfdump var=#evaluate(i)# label="#i#">
</cfloop>

When I navigate to cb.domainname.com, the "Welcome to the Railo World!" page is displayed, not the index.cfm file I created.

User avatar
Posts: 9
Joined: 19 Aug 2014, 20:38

Re: New Template Installed to Old Template Location

25 Aug 2014, 09:24

Update:

I created a VM with Server 2012 and installed Helicon Zoo. I installed the CFML hosting package, Java SDK, Tomcat and the Railo 4 Tomcat template.

I followed the same steps from my post from last night and ended up with the same exact results.

However, I decided to go against your advice and add a new hosts entry to server.xml, which resolved my problem.

Thank you for the time you've tied up assisting me.

User avatar
Posts: 110
Joined: 07 Mar 2012, 10:22

Re: New Template Installed to Old Template Location

26 Aug 2014, 06:04

Hello,

Sorry for delay.

It looks like some issue.
Could you add these lines into C:\railo4\tomcat\conf\logging.properties to enable logging for HeliconZooTomcatValve.jar.

Code: Select all
5com.helicontech.zoo.FileHandler.level = FINE
5com.helicontech.zoo.FileHandler.directory = ${catalina.base}/logs
5com.helicontech.zoo.FileHandler.prefix = zoo.

handlers = 1catalina.org.apache.juli.FileHandler, 2localhost.org.apache.juli.FileHandler, 3manager.org.apache.juli.FileHandler, 4host-manager.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler, 5com.helicontech.zoo.FileHandler


Restart Tomcat server, make several requests via IIS/Helicon Zoo and show zoo.*.log files.

Thank you.

Return to Helicon Zoo

Who is online

Users browsing this forum: No registered users and 0 guests