Skip to main content
Participant
June 19, 2009
Question

Development Server

  • June 19, 2009
  • 2 replies
  • 1078 views

Hi,

I use OSX on a 64-bit Mac Pro with Leopard 10.5.6. I install 64-bit software if possible.

From previous posts I am still newbie here. I have a problem with setting up a development environment. I just don't feel comfortable in what I have. I think there must be better ways. But most of training has been in code not this stuff, so I am trying to see how to set this up right.

I use cfeclipse. I was using DW but I really like the method view in cfeclipse etc. Even though I think DW is a better product it really lacks things I would like to see for coldfusion and is too full of stuff I code myself that gets in my way. I hope bolt solves all this. I also use textmate but it is to simple for real coding tasks, even though I think it is very good it's CF support is not as good as that for PHP. I was wondering what you are using and on what platform?

Secondly how do you set up your testing server?

I use Apache (64-bit) connected to CGI/PHP/CF and MySQL. The one that works the worst for me is CF. It just keeps breaking Apache.

I think this is because I am not understanding how to set CF up right or the 64-bit version on OSX has issues. If you have links or tips on the install of CF I would be very grateful to see how you are doing it.

If you have any URL's a cfdump here would be appreciated. I am a newbie who has spent all his time in code and forgot this needs attention. So if you can help with any tips or links it would be appreciated!

Thanks Guys!

Yes I google but I am asking other coders not google here.

Scott

This topic has been closed for replies.

2 replies

Inspiring
June 19, 2009

Hi, Scott,

Sorry this is so long. I spent a lot of hours creating my Mac development environment, so I feel your pain ! I hope some of it helps you.

I develop on a Mac (OS X 10.5.7) and have ColdFusion 8.0.1 integrated with my Apache 2.2.9 installation. When I installed ColdFusion, I chose the multi-server installation. Note that there has been some weirdness with the 64-bit Mac installer of CF 8.0.1 (Google for "64-bit ColdFusion 8 Mac" and you'll see loads of hits).

I don't like the standard Apache that comes with the Mac (it's a little too customized for the environment and more of a pain to edit). So, I shut down that Apache (I did not uninstall it; rather, I keep it installed but dormant) and installed a custom Apache with MacPorts. I prefer this because I was able to 'build' my own Apache with support for PostgreSQL, MySQL, PHP (including loads more PHP extensions than come in the 'standard' Mac Apache), etc. There's a lot of great stuff you can easily install, update and remove via MacPorts. If you haven't yet, check it out.

When I connected CF and Apache, it was before the 8.0.1 updater/installer, so I had to manually build the connectors. Aaron West has a great post on it:

http://www.trajiklyhip.com/blog/index.cfm/2008/1/14/ColdFusion-8-Apache-22x-and-OS-X-105-Leopard

Mark Drew also has an excellent post on CF8 and Leopard:

http://www.markdrew.co.uk/blog/post.cfm/running-coldfusion-8-on-leopard

With CF and Apache connected, I made my Apache web root (/Users/myusername/Sites) the web root for CF as well. Then, in TextMate (I do like TextMate; great overall editor), I created a project for my Apache configuration files (httpd.conf, hosts, httpd-vhosts.conf, etc). For each Cf site/project I'm working on, I do two things with my Apache config: (1) add a new domain to my Mac hosts file, which is in the folder '/etc' and (2) add a new virtual host to the httpd-vhosts.conf file.

If I'm building a site for www.somecoolcfsite.com, I'll first create a host entry for dev.somecoolcfsite.com. This directs any (browser) requests to dev.somecoolcfsite.com to my localhost (127.0.0.1). Then, in the Apache virtual hosts definitions, I setup an entry for this domain, which directs to the correct folder in my web root. Here's a sample VHOST entry:

<VirtualHost *:80>      ServerName dev.mysite.com      ServerAdmin server-admin@gmail.com      DirectoryIndex index.cfm index.html index.htm      DocumentRoot /Users/myusername/Sites/mysite_com </VirtualHost>

Now my development site will behave exactly like the production site, which I like. For me, this makes deployment much easier with fewer issues to watch for.

IDEs are another topic altogether, because so much of it is uber-personal. For me, I prefer Aptana Studio (I do a lot of Ajax, AIR, and mobile site work) with the CFEclipse plugin installed for my CFML development. I don't care for Dreamweaver at all (sorry Adobe!), even with the positive updates implemented in CS4. I find it bloated and cumbersome on the Mac and, still, geared more toward visual developers than coders.

If you're just coming into the CF world, Eclipse-based solutions (Aptana, Eclipse itself, CFEclipse, Flash Builder, etc.) are the way to go. Additionally, Adobe's first ever CFML IDE (previously code-named Bolt but just this week officially named ColdFusion Builder) is based on Eclipse, just as Aptana and Flash Builder are. While Dreamweaver isn't going anywhere, ColdFusion Builder is more the future for CF developers.

Again, sorry for the extensive post but I could relate to it and wanted to share how I got my development environment going on my Mac.

Cheers, Craig

Participant
June 19, 2009

Thank You Craig your a star!

I was on my way to this but I was getting confused and now I see the light! I am learning on my own in isolation, so it is always tricky to know what others are doing in regard to a development environment. I can see open source code I steel (ahhhhem download) and I can read books but I can't see people working.

It is not a one way documented area probably because of all the different ways to set a test/production environment up (different os's, web servers, DBMS, IDE's etc). So you need to try and play about and come up with your own ways that work good for you from what I can see.

I am still learning so I don't have a production server to match too but I do take this point strongly on board also.

Thank you guys for taking the time to outline these KEY principles. I can take what you said and implement it. Wonderful post, really helpful.

Scott

Inspiring
June 19, 2009

Glad the post was somewhat helpful, Scott! If you get stuck in the Mac-CF world, feel free to PM me. I can't even count the number of times I've reinvented my dev environment since I went to Macs at the end of 2006!

Inspiring
June 19, 2009

I use DW on Windows.  I only use code view that the only panel or toolbar I display is the insert toolbar.  This allows be to quickly comment out large blocks of code.

Development and Testing enviornments should resemble the production environment as closely as possible.  Otherwise, things might work differently, or not at all, when you move them to production.