Link to home
Start Free TrialLog in
Avatar of WestCoast_BC
WestCoast_BCFlag for Canada

asked on

Railo configuration

I have just installed Railo and the URL that I use to get my home page to display is:

http://localhost:8888/index.cfm

the problem that I am having is that my relative links are not preserving the :8888 and so my page doesn't work.

For example, if I try to use:
http://localhost/index.cfm?page_id=56&menu_id=60&Label=Terms%20of%20Use

I get an error but if I use
http://localhost:8888/index.cfm?page_id=56&menu_id=60&Label=Terms%20of%20Use

the page displays fine. How do I preserve the :8888 in my relative URLs

Thank you.
Avatar of Randy Johnson
Randy Johnson
Flag of United States of America image

If the link is actually

<a href="/index.cfm?page_id=56&menu_id=60&Label=Terms%20of%20Use">My Link</a>

Open in new window


or

<a href="index.cfm?page_id=56&menu_id=60&Label=Terms%20of%20Use">My Link</a>

Open in new window


it should preserve the URL.  Can you confirm this is how you have your links set up?
Avatar of WestCoast_BC

ASKER

My link looks like:
<a href="index.cfm?page_id=56&menu_id=60&Label=Terms%20of%20Use">My Link</a>

but it does not preserve localhost:8888

it just uses localhost and then my page does not display
Do I need to configure my IIS Manager?
I removed a mapping that I had set in the Railo Admin so now my URL looks like:

http://localhost:8888/portal/_SampleSites/MySite/index.cfm

Problem is that now when I try to load a JS file using a relative link it tries to use the URL:

http://localhost/js/popup.js

Not only does it not preserve the :8888 after the localhost but it also loses the path information (../portal/_SampleSites/MySite/..).

Is there some configuration that I am missing. I also have ColdFusion server installed on this computer but it is not currently running. When I use it my site displays without problems.
I have also tried copying all of my source to the Railo Root directory (../webapps/ROOT) and I get the same problem. Is there a way for me to point localhost to the correct location so if I use it without :8888 it still works?
You have 2 options for that.

1.  Configure IIS for the front end.   Installing from the railo installer will install the iis connector.

2.  If you want to use Tomcat / Jetty as the web server you just have to dive into the config files and change it from port 8888 to port 80.  If you tell me how railo is installed I can point you to the correct file or you could use a program like notepad++ or editplus to search all the files in the railo directory for 8888 and change to 80.  Restart railo and you are good to go.
Thanks - How do I configure IIS?
Install railo from the officiall installer and it has the option to install the connector for you.  I will research more detail for you tomorrow.
I have installed Railo Express and it did not give me an option to install the connector.  Do I need to install the full version of Railo?
Yes, definitely.  Install the full version.  Let me know if you have any hiccups.
Instead of installing the full version can I change my Railo configuration to use port 80 instead of 8888? If so do I need to change the start.bat file to read:

"jre/bin/java" -DSTOP.PORT=8887 -DSTOP.KEY=railo -javaagent:lib/ext/railo-inst.jar -jar start.jar --module=http jetty.port=80

and do I need to edit the jetty.xml file and add the line:

<Set name="port"><Property name="jetty.port" default="80"/></Set>

Is there anything else that I need to do or is this not possible? When I made the above changes and try to access my site I now get the error:

HTTP Error 404.3 - Not Found
The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map.
ASKER CERTIFIED SOLUTION
Avatar of Randy Johnson
Randy Johnson
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I am not very knowledgeable with setting this up and I am not sure what I need. I just noticed that I had IIS setup and it was using port 80 which is why I thought I might need to change my Railo to use port 80 as well.  How do I know if I am using jetty or IIS as my web server? I just use the start.bat that was installed with Railo to get it started. I don't think my changes are correct since I now can't get Railo to start so I am undoing the changes mentioned in my previous post
You already told me you used Railo Express.  You need to uninstall that and install the normal railo installer.  That will setup the connector from IIS to railo to allow you to use port 80.  The railo installer is easy to do.. basically you just need to choose the defaults but make sure you click the option to setup the iis connector.
Thank you but I now have it working with Railo Express so I will continue to use what I have now. I may try in the future to install the full Railo but for now I will keep what I have since it does seem to work.
ok cool. as long as you are up and running!
To recap: To get Railo to work I disabled my IIS and I changed the port that Railo was using from 8888 to 80 by modifying start.bat to be:

"jre/bin/java" -DSTOP.PORT=8887 -DSTOP.KEY=railo -javaagent:lib/ext/railo-inst.jar -jar start.jar --module=http jetty.port=80
I've requested that this question be closed as follows:

Accepted answer: 0 points for WestCoast_BC's comment #a40220028

for the following reason:

I solved my own problem
I suggested the author's resolution in #2 of response above:  2014-07-21 at 20:48:17 ID: 40210524