How to start Railo from a CD

Ever wanted to give a website to somebody on a CD-ROM. Not just some plain HTML but with some server side like in your server or localhost machine. Railo offer us this opportunities what you need to do it’s to download this version of Railo from this blog post where Gert explain how to do it for a usb stick.
Unzip the version you have in a folder ex: c:\Railo_CD
You need to do the entire configuration before you burn everything because you cannot rewrite as you want on a CD like a USB sticks.

1- Launch railo via the c:\Railo_CD\start.bat wait until you see something like that
====================
WEB CONTEXT
--------------------

2- Upgrading Railo to the last version
The version you download it’s .015 you can go on the server admin via your browser
http://localhost:8080/railo-context/admin/
Services -> Update -> Execute Update

3- Bring all your website content into a new folder under the webroot for example
c:\Railo_CD\webroot\myNewApplication

4- Test your application in your browser if everything works
http://localhost:8080/myNewApplication
You should think to remove the debugging in the server and also in webcontext because I’m sure your client doesn’t need it.

5- If everything works now it’s time to start to modify some files to make, if not try to figure out what doesn’t work and fix it.

6- We don’t need to have the jvm.log and the access.log we need to remove them for that we go to this file c:\Railo_CD\conf\resin.conf
Comments these 2 lines
Line 35

Line 268 .. 270
<br />format='%h %l %u %t "%r" %s %b "%{Referer}i" "%{User-Agent}i"'<br />rollover-period="1W"/&amp;gt;

7- We need to move somewhere the logs files of Railo for that we edit this file c:\Railo_CD\webroot\WEB-INF\railo\railo-web.xml.cfm Everywhere where you see a mention for logs you put instead {temp-directory}\ in front like that everything will be written to the RAM of the computer.
Line 45

become

Line 74

become

Line 76

become

Line 90

become

Line 154

become

7- Burn the folder on a CD and you can start Railo via the CD

8-Voila

I know you will ask no database I will write another post for that. I was able to manage to run Railo with an H2 database via CD only in reading mode for sure.

| View count: 1268
del.icio.us Digg StumbleUpon Facebook Technorati Fav Google Bookmarks DZone