Run multiple websites from one framework

47 views
Skip to first unread message

Everett

unread,
Jan 4, 2010, 1:40:32 AM1/4/10
to ColdFusion on Wheels
I'm just starting to explore CFWheels and so far I'm very impressed.
However, I've run across one stumbling block and was curious if anyone
else knows of a solution.

With other frameworks like Fusebox, ColdBox, etc. you simply put the
framework at your web root or elsewhere (never tried this) and then
reference them in your web application. The advantage of this is that
you can have multiple independent sites running off of one install
base and if you ever need to update the framework you simply replace
one folder. Is it possible to do the same with CFWheels?

tpet...@gmail.com

unread,
Jan 4, 2010, 8:58:15 AM1/4/10
to ColdFusion on Wheels
no currently, however it is in the list of todos

Everett

unread,
Jan 4, 2010, 1:49:51 PM1/4/10
to ColdFusion on Wheels
Okay, thank you for your reply.

wfisk

unread,
Jan 4, 2010, 3:14:57 PM1/4/10
to ColdFusion on Wheels
I am not sure if really is such an advantage to have just one install
of the framework.
I think its just because that's what you're used to with Fusebox,
Coldbox etc...

In fact, one thing I really, really like about CFWheels is that each
application is self-contained. I can update the framework on each
application when I please; and updating the framework on one
application does not affect the others. Also updating is not such a
big deal, but you still need to test each application to make sure it
still works correctly.

William

tpet...@gmail.com

unread,
Jan 4, 2010, 3:36:06 PM1/4/10
to ColdFusion on Wheels
the cool thing would be to allow both. if i'm not mistake rails allows
you to "vendor" or "freeze" a version of rails into a specific app.
this way you can either have your entire server run off one copy or
each have it's own copy if you desire.

Russ Johnson

unread,
Jan 4, 2010, 3:37:46 PM1/4/10
to cfwh...@googlegroups.com
Yeah thats how rails handles it.. I like that approach as well...

> --
>
> You received this message because you are subscribed to the Google Groups "ColdFusion on Wheels" group.
> To post to this group, send email to cfwh...@googlegroups.com.
> To unsubscribe from this group, send email to cfwheels+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/cfwheels?hl=en.
>
>

Chris Peters

unread,
Jan 4, 2010, 8:49:20 PM1/4/10
to cfwh...@googlegroups.com
I believe this is the issue related to this request:
https://code.google.com/p/cfwheels/issues/detail?id=319

We've got it scheduled for 2.0 for now unless we can figure out a way to get it working without needing to change anything else in any of the other folders besides the core wheels folder.

John C. Bland II

unread,
Jan 4, 2010, 11:17:47 PM1/4/10
to cfwh...@googlegroups.com
You seem to be thinking server-wide, which is cool, but on a per app basis I may want to run two apps off the one.

For instance, my admin site wouldn't be the same app as my main site. It could be but probably wouldn't be. Take a quick look at how ASP.NET MVC 2 handles it with Areas: http://haacked.com/archive/2009/07/31/single-project-areas.aspx. Having recently used them (well, doing so now) I completely love the Areas in MVC 2. Our ControlPanel app is using the same data model but it is a separate app in terms of views, routing, etc. Love it. :-)

This, or some form of it, would be a great addition to CFw.

---
John C. Bland II
http://www.johncblandii.com
http://www.johnandseason.com
http://www.twitter.com/johncblandii
---
Suggested sites:
http://www.lifthimhigh.com - "Christian Products for Those Bold Enough to Wear Them"
http://www.sportsmatchmaker.com - "What are you doing today?"


wfisk

unread,
Jan 5, 2010, 3:34:27 AM1/5/10
to ColdFusion on Wheels
Even without including Rails in your application, you can have
serveral versions of Rails installed on a machine. Rails stores the
version number in the the file config/environment.cfm. That way your
application can continue to use an older version of Rails even if a
new version is installed.

wfisk

unread,
Jan 5, 2010, 4:05:44 AM1/5/10
to ColdFusion on Wheels
I can see the idea. The applications I am writing are not that big
(about 30-40 tables) and are all self-contained (they don't need to
communicate with anyone else), so I don't have that need. And in fact
that's why I like CFWheels so much.

But I can see that the MVC approach can become a bit tiresome if you
have lots of tables and wish to divide the application into several
modules - or several applications. Or maybe for security reasons you
want to have two applications using the same data model. So you can
deliver one version of application which does not even include any
sensitive code.

One thing here that would be nice would be able to create sub-folders
in the Controllers/Models/Views folders and store controllers/models/
views in sub-folders. And if you've working in Mac/Linux then one of
these sub-folders could be a symbolic link to a real folder in another
application.

A Rails approach would be to use REST, and create one application that
serves up the data in XML format and the other applications that
communicate with it (rather than directly with the database). I like
the sound of this but I've never tried it.

Another idea, which I've also never tried (hey, but ideas are easy),
is to create all you data access code in the Models as a plugin and
then install that plugin in your applications.

William

On Jan 5, 5:17 am, "John C. Bland II" <johncblan...@gmail.com> wrote:
> You seem to be thinking server-wide, which is cool, but on a per app basis I
> may want to run two apps off the one.
>
> For instance, my admin site wouldn't be the same app as my main site. It
> could be but probably wouldn't be. Take a quick look at how ASP.NET MVC 2
> handles it with Areas:http://haacked.com/archive/2009/07/31/single-project-areas.aspx. Having
> recently used them (well, doing so now) I completely love the Areas in MVC
> 2. Our ControlPanel app is using the same data model but it is a separate
> app in terms of views, routing, etc. Love it. :-)
>
> This, or some form of it, would be a great addition to CFw.
>
> ---

> John C. Bland IIhttp://www.johncblandii.comhttp://www.johnandseason.comhttp://www.twitter.com/johncblandii
> ---
> Suggested sites:http://www.lifthimhigh.com- "Christian Products for Those Bold Enough to
> Wear Them"http://www.sportsmatchmaker.com- "What are you doing today?"

> > cfwheels+u...@googlegroups.com<cfwheels%2Bunsu...@googlegroups.com>

Reply all
Reply to author
Forward
0 new messages