My blog has moved
Please update your bookmarks and feeds for my site.
I now have a Mango Blog at:
http://www.andyjarrett.com/blog
Feed URL: http://feeds.feedburner.com/andyjarrett
Please update your bookmarks and feeds for my site.
I now have a Mango Blog at:
http://www.andyjarrett.com/blog
Feed URL: http://feeds.feedburner.com/andyjarrett
This was meant to be a guide about setting up your server with Linux, Railo, Apache, and MySQL but I've dropped Apache. Why? Well its an overhead I don't need. Resin functions perfectly well as a HTTP server and it does all I need. Why add another bit of software to fail? .... simplify :) In the long run I might change but for now I'd rather save the resources.
So ... where did this guide come from considering there are quite a few guides for this setup? Well for one reason or another I just didn't get on with them and by the end something went wrong which was mainly because I am Mac boy more than a Linux guy and sometimes I just missed the points here and there. The aim of my guide is to be clear and simple. So with a fresh Ubuntu install i'm planning on gettingt Railo running via Resin so I can call http://www.mysite.com/index.cfm
I won't lie, to make this post I have "borrowed" from other sources out there which I will try and link to at the end.
Im running Ubuntu 8.10 (Intrepid) without a graphical interface.
Note: If you are doing this on a clean, new server then before you even read on check out Slicehost.com documentation about setting up a Ubuntu server. These guides are the best and clearest I've seen online to date and cover everything you need!!!!
On to Railo
I'll be honest, I don't have much linux experience. I've always liked the idea of Linux and a command line driven OS but as soon as I see the GUI I tend point and click, which means I don't learn anything new. Then comes along JeOS (Just enough OS, pronounced as "juice") from Ubuntu which doesn't give you a GUI, it just gives you the bare minimum to run a server. It's designed for VM's and perfect for running a Subversion server on your local machine in the background. The specs are:
So with JeOS and VMWare Fusion armed I was ready to setup a light-weight Subversion and Apache server. Below documents what I did to get a single SVN repository up and running. Im not installing Trac or SSL with this just so you know. I might try and cover them later, along with multiple repositories.
Setting up JeOS with VMWare fusion is no different than setting up any other VM so I won't go over that here. I'll assume that you can do that, and have done that and now at the command prompt.
Obviously because there is no GUI supplied all commands have to be run from the Command Line/Terminal. This also means editing txt files from the terminal too. If you've never used VIMM you might want to have the following URL handy www.gnulamp.com/vi.html
First things first, lets make sure your install is up-to-date.
Passing defaultProperties in ColdSpring with Model Glue
Or Using defaultProperties with CS and MG. I couldn't figure out which title would be better.
Basically this is a guide on how to pass variables into ColdSpring. In my case from the Application scope. Recently I've been working on a Model Glue, Transfer, and ColdSpring app and came across a problem which I couldn't find a direct answer to online. The application I'm working is only a small part of the site and has some settings in the Application scope which needs to remain there. Usually I put all my variables in a ColdSpring/Model Glue simpleConfig Bean (using the class ModelGlue.Bean.CommonBeans.SimpleConfig) but this time I needed CS to get the variables from the application scope. This actually isn't too hard as you can pass properties(dynamic variables) into the config.xml e.g.
Here's the code for creating the bean factory. You would find this in onApplicationStart or at the top of your Application.cfm.
Code for Application.cfm/cfc
In our Beans.xml we need to reference the properties structure by the key.
I love working with Transfer and Mark Mandel has done an amazing feat of giving it some really good documentation. But I remember when I was getting started I was looking for a rough guide to the TQL language for Transfer and how to implement it. So based on all the information at www.transfer-orm.com/transfer/documentation/ here's a quick start to TQL.
Please note: I am presuming you already know how to set up Transfer and have basic knowledge of how it works.
For this example here is our Transfer.xml configuration file:
The other title was, How I added the FeedBurer URL to BlogCFC - imagine whatever your prefer :o)
If you haven't heard Feedburner has recently been acquired by Google. Which as it seems with all Google acquisitions means us users end up getting something free out of it and to with keep up traditions Feedburner now offer their "Pro" services for free.
Critter on a previous post asked "if you can pass in attributes to the build.xml file?" From the Terminal this is as easy as adding another argument "-D".
I'm gonna try and cover the two OS's here so be kind.
First things first, goto http://ant.apache.org/bindownload.cgi and download the appropriate archive (zip) file: apache-ant-[VERSION NUMBER HERE]-bin.zip
I know that I've done a post on copying files with Ant, but I really want to take this further and into more detail. To save my fingers a lot of the text below is taken from my first post as moving and copying directories/files is a similar command in principle.
I also want to mention that I am running all my Ant tasks via Eclipse and not the command line. If there is a demand to know how to install Ant and run it from the command line I'll do that post separately. At this point I'm assuming you've got Eclipse and you know you way around it enough? Before we do begin you will need to ensure that you can see the Console 'View', you can get to this by going to:
First off I wanna say that I'm running all my Ant task via Eclipse and not the command line. If there is a demand to know how to install Ant and run it from the command line I'll do that post separately.
So, what is Ant? Well to steal a quote from Mark Drew, think of Ant as .bat files on steroids. You use XML to describe a set of commands to run a whole range of tasks to do anything from SVN/CVS checkouts, unit tests, FTP, emails, sql, moving/copying folders/files generally just name it!
In this guide I want to cover creating a build.xml file and moving files/folders. I'm assuming you've got Eclipse and you know you way around it enough. Before we do begin you will need to ensure that you can see the Console View.