"There's no place like home...."
June 27, 2006 10:55 AM   Subscribe

Need a tinker-free Linux/MySql install for Ruby On Rails. Also, seeking advice for getting started in RoR.

Ok, I'll start this out by saying that I have little-to-no interest in operating systems. I've run Windows for the past decade or so because (for me, anyway) it's a no-effort solution that requires the least tinkering possible.

HOWEVER, I've recently been teaching myself Ruby On Rails, and it seems that RoR is most comfortable in a Unix/MySql environment. So here are the questions -

1) Am I correct in the assumption that the standard RoR setup is Unix/MySql? Is this what RoR is most comfortable with? Has anyone successfully run RoR on WinXP/SqlServer?
2) What Linux installation requires the least tinkering to get it to work properly?
3) Which Linux installation has the best community support?
4) Is there a way to install linux as a dual-boot on my WinXP system without reformatting, repartitioning, and reinstalling everything? Bonus points for solutions that involve only free tools.
5) What are some good MySql resources? Specifically, I'm looking for guides to dealing with installation and administration. Also, what are the best MySql community sites?
6) What resources would you suggest for someone starting out in RoR? I'm currently reading Why's (poignant) Guide to Ruby as well as Agile Web Development In Rails. Are there any other books or guides that you would suggest? Are there any places where I can get some good sample code to play around with? What are some good community sites? (I should mention that I'm an experienced programmer, so I'm specifically looking for help with Ruby, not programming in general)

Sorry for the ton and a half of questions. If you could answer *any* of the above, your help will be greatly appreciated.
posted by Afroblanco to Computers & Internet (19 answers total) 4 users marked this as a favorite
(1) Yes, but you mean Linux/Mysql.
(2) Ubuntu is pretty good. I would use Xubuntu myself. Yes people run rails on windows; here's a setup guide for Rails on windows
(3) Ubuntu is pretty good
(4) Get a second hard disk and boot off that maybe; otherwise you'll need some partitioning. You can perhaps use PartitionMagic. OR you could run cygwin. But really, just set up an old computer for this; it's easier.
(5) The Mysql site actually has very good documentation. They even have a section for ruby.
(6) I have no good suggestions about rails as I do not use it.
posted by beerbajay at 11:08 AM on June 27, 2006

Oh and you can run mysql on windows, no problem. Don't even bother with SQLServer as this is not what you'll be using out in the world (assuming you want to be employed doing RoR).
posted by beerbajay at 11:13 AM on June 27, 2006

You can get free stuff from VMWare to run a virtual Linux machine inside your existing XP install. I have a copy of VMWare Workstation which is still a pay product, but I'm guessing that Server would do the trick.
posted by lowlife at 11:17 AM on June 27, 2006

Questions #2,4: Hey, here's a Ruby on Rails live cd!
posted by boo_radley at 11:33 AM on June 27, 2006

Oh yes. VMWare would be a much more elegant solution. Do that.
posted by beerbajay at 11:49 AM on June 27, 2006

Best answer: The semi-official Ruby Book is the Pickaxe - it's not the language definition but it's more or less the authority. The first edition is online for free. The Agile Rails book is definitely the best beginner's guide, to my mind, cowritten by DHH (Rails creator). The Rails Wiki is very spotty but there's a bunch of sample code lying around, though as usual YMMV depending on exactly what you're after. Curt Hibbs did the first popular Rails tutorial, and a handful of other tutorials are around, most of them fairly trivial.

Apple's OSX Rails tutorial is quite nice as well, actually.

Why's Ruby guide is hilarious and beautiful and a truly literary creation and whatnot, but I can't decide whether it's actually a good teaching tool for the language. The bullshit::content ratio is a little too high.

Rails is somewhat poorly documented overall at this point; an effort is underway to correct that. The API docs are of course the main source but they're not perfect. The Agile Rails book is the place to start - from there you should be able to gauge the worth of other online resources.
posted by waxbanks at 1:26 PM on June 27, 2006

Stop, you're both right! The Ruby on Rails Live CD can be run from VMWare. So you don't have to repartition, reinstall, or even reboot.

You just download the live CD image (which you would usually burn to a disk and boot to directly), download the vmx file (which tells the VMWare player to use the CD image), and download and install the VMWare player. Put the .iso in the same directory as the .vmx file, and it should be as easy as double-clicking the .vmx file. Voila. You will have a linux/rails development environment running right on your windows desktop.

Disclaimer: I haven't actually tried this live cd, in a virtual machine or otherwise. You voila may vary.
posted by team lowkey at 2:00 PM on June 27, 2006

So I went ahead and tried it, and there was a snag, but not an insurmountable one. When you double click the vmx file, it tells you there is no disk found. The reason is that it's looking at the physical CD-Rom drive.

There are buttons at the top of the VMWare screen for CD-ROM and CD-ROM 2. While the player is in it's initial "Starting" screen, you need to Click the CD-ROM button to disable it, and click the CD-ROM 2 button to enable it. When you get the "boot:" prompt, click in the screen press enter.

The username and password are "rails". Oh, and you press Ctrl and Alt to get your mouse pointer out of the virtual machine and back to your desktop.
posted by team lowkey at 2:47 PM on June 27, 2006

Best answer: There is also a pre-installed Rails Appliance on VMTN. Same principle as the Live CD, but has the software already installed.

(disclaimer: I work for VMware.)
posted by troyer at 4:37 PM on June 27, 2006

Response by poster: Thanks to all for your answers.

I'll definitely be picking up a copy of the Pickaxe.

As far as the operating system stuff goes :

I'm not sure if the Rails Live CD is for me. I would like to develop full database-driven applications that I could then deploy and let my friends use. It doesn't seem like the Rails Live CD is geared toward this.

VMWare might be a good solution. However, I would like to be operating in an actual server environment, so that there will be a minimal of snags when I actually deploy the application. I don't really know a whole lot about VMWare, to be honest. Is it "the same" as having an actual distribution of Linux installed on my machine? Also, I noticed that there is a free version and a pay version. Is the free version crippled in any way?

So far, the best option seems to be "install linux on a seperate hard drive." I happen to have an extra hard drive lying around, so this could work. (really) stupid question time - will the WinXP boot loader let you boot Linux from a drive other then the one that contains WinXP?

As far as linux distributions go, so far we have 1 vote for Ubuntu/Xubuntu. Any other suggestions? I originally figured that RedHat would be the easiest, since it seems like the most popular, but I could be wrong.
posted by Afroblanco at 6:00 PM on June 27, 2006

Hey, troyer: you people do good work.
posted by boo_radley at 6:40 PM on June 27, 2006

VMWare is great stuff. The free workstation player works in all respects except you cannot create a fresh virtual machine using it, you can only VMs that are already created. You can then use VMWare's networking support to connect one VM to another or (I think) connect your machine to the VM running a server.
posted by lhauser at 8:45 PM on June 27, 2006

You could have:

(1) a linux server running at all times to serve up the apps to the general public
--> Get a separate machine, install ubuntu, develop on your windows workstation. You are now a systems administrator and are responsible for security, etc.

(2) a linux-based workstation where you can use the normal linux tools to build your app
--> Get a separate machine, install ubuntu, develop here; you can use this as a public server as well, but probably shouldn't.

(3) a test system that will simulate a server so that you can learn the toolset, but which will not be open to the public
--> Use the VMWare ROR environment proided by troyer
--> OR Use VMWare, install ubuntu, probably still do development in windows and plonk it over into the vmware environment(?)
--> OR just install mysql/ror for windows
posted by beerbajay at 3:36 AM on June 28, 2006

Redhat will not be easiest. If you just want a working workstation as fast as possible, ubuntu is probably your best shot and it's the flavor of the month, so there's an active community and still with good support. (I voted twice, sorry)
posted by beerbajay at 3:39 AM on June 28, 2006

Grawr. For (2), you could also do the whole dual-booting thing.
posted by beerbajay at 3:40 AM on June 28, 2006

Response by poster: Thanks again for the help.

To be honest, I'm not completely sure what VMWare is or what it does. A few questions -

1) Does it set up a file system?
1a) If so, does the file system persist? (i.e. If I create a file, will it be there again the next time I start VMWare?)
1b) Will it let me install MySql?
2) When I want to transition my app from VMWare to a dedicated Linux server, will there be any snags because the app was developed under VMWare?
3) Is the free version of VMWare crippled in any way?
posted by Afroblanco at 7:17 AM on June 28, 2006

Best answer: VMWare provides a "virtual machine" so that you can run other operating systems within your current operating system. Think of NES/SNES emulators. It's kind of like that, but not.

(1) If you use the (free) RoR appliance, I'm pretty sure that'll come with a filesystem all ready for you. I'm not sure how that's handled if you install a fresh system into a new virutal machine.

(1a) Yes, it should.

(1b) Yes, it will. If you use the RoR appliance/image from above, you'll get mysql preinstalled.

(2) Shouldn't be any problems; it's just code.

(3) I'm not 100% sure about this; but I'm pretty sure that the free server isn't crippled, though it might have fewer features than other VMware products. Most likely it is fully functional but does not have the same performance as a version you might use in production.
posted by beerbajay at 9:20 AM on June 28, 2006

Response by poster: Excellent. Thank you for answering my questions. I think I'm going to try the VMWare RoR appliance.
posted by Afroblanco at 10:09 AM on June 28, 2006

After reading the Agile/Rails book you might like to check out Rails Recipes, from the same publisher. Also note that there is a new edition (sorry) of the Agile/Rails book on the way (beta copies can be purchased for download).
posted by Songdog at 10:53 AM on August 3, 2006

« Older Help with my ink   |   Girls and gaming Newer »
This thread is closed to new comments.