Ruby, Rails & Linux - Which distro?

Hi,

I’ve been doing most of my initial playing with rails on a windows
system - but wish to switch to a dedicated linux box for this.

Are there any particular distro’s to avoid / recommend. I prefer debian
for my other stuff, but thought i’d ask before going ahead. :slight_smile:

Cheers

Debian Sarge works great.

Cheers,

Ed

Edward F. wrote:

Debian Sarge works great.

I will second that, apart from getting lighttpd working which is a
complete pain in the arse. Such a pain in the arse that I used Apache
and mod_fcgid instead
(Peak Obsession).

It has been fine so far. Where I had previously had stability issues
with mod_fcgi, mod_fcgid is working great.

Will.

On Friday 21 April 2006 12:29, Guest wrote:

I’ve been doing most of my initial playing with rails on a windows
system - but wish to switch to a dedicated linux box for this.

Are there any particular distro’s to avoid / recommend. I prefer debian
for my other stuff, but thought i’d ask before going ahead. :slight_smile:

Unless you have a specific reason for wanting the Linux kernel
underneath your
software, you could look at FreeBSD. The base system is stable, easy to
use
and easy to keep up-to-date, and the ports tree is huge and well
maintained.
I’ve never used lighttpd on it (I’m looking at that next), but have no
trouble with Apache.

Ashley

I moved from debian to ubuntu and I’m very happy

Guest wrote:

Hi,

I’ve been doing most of my initial playing with rails on a windows
system - but wish to switch to a dedicated linux box for this.

Are there any particular distro’s to avoid / recommend. I prefer debian
for my other stuff, but thought i’d ask before going ahead. :slight_smile:

Cheers

On Fri, Apr 21, 2006 at 12:56:02PM +0100, will wrote:
} Edward F. wrote:
} >Debian Sarge works great.
}
} I will second that, apart from getting lighttpd working which is a
} complete pain in the arse. Such a pain in the arse that I used Apache
} and mod_fcgid instead
} (Peak Obsession).
}
} It has been fine so far. Where I had previously had stability issues
} with mod_fcgi, mod_fcgid is working great.

I never tried anything other than Apache2 + mod_fcgid, and I had little
trouble setting it up. I use a Debian Testing/Unstable mix (though I’d
use
sarge for deployment).

Incidentally, if you want rubygems (you probably do) and you want to
keep
them in /usr/local/lib instead of /usr/lib (following Debian policy),
you’ll need to do some work. I’m including a shell script that will let
you
install gems in /usr/local (or wherever). There is also some attempt to
wrap gems in Debian packages so that they are managed by apt/dpkg, but I
don’t know how far that effort has gotten.

Also, anything you can install via apt (e.g. RMagick, native postgresql
ruby
driver, etc.), you should.

} Will.
–Greg

#!/bin/sh

if test $# -ne 1 || test ! -d “$1”
then
echo “Usage: $0 ” >&2
exit 1
elif test ! -r setup.rb
then
echo “Please run from the toplevel RubyGems source directory” >&2
exit 2
fi

PREFIX=“sh -c \"cd \"$1\"; /bin/pwd\"
GEM_HOME=“$PREFIX/lib/site_ruby/gems”
export GEM_HOME

if test -d “$GEM_HOME”
then
cat <<-EOF >&2

The GEM_HOME directory already exists. Overwriting an existing
install will not work well. If you intend to reinstall, please
first remove $GEM_HOME

EOF
exit 3

elif ! mkdir -p “$GEM_HOME”
then
cat <<-EOF >&2

You do not have permission to install in the directory selected.
Perhaps you meant to install as root?

EOF
exit 4

fi

while test ! -e “$GEM_HOME/bin”
do

echo -n "Where should executables be installed [$GEM_HOME/bin]? " >&2
read dest

if test "$dest" = "" -a "$dest" = "$GEM_HOME/bin"
then
	dest="$GEM_HOME/bin"
	mkdir "$dest"
elif test -d "$dest"
then
	dest="`sh -c 'cd \"$dest\"; pwd'`"
	ln -s "$dest" "$GEM_HOME/bin"
else
	echo "You must choose an existing directory." >&2
fi

done

ruby setup.rb config --prefix=“$PREFIX”
–siteruby=$prefix/lib/site_ruby &&
ruby setup.rb install

cat <&2

################################################################################

Be sure to set the GEM_HOME environment variable in your shell’s
init/config file to ‘$GEM_HOME’

For Bourne shell derivatives, add the following lines to your
~/.profile or the system-wide /etc/profile:

GEM_HOME="$GEM_HOME"
export GEM_HOME

For C shell derivatives, add the following line to your ~/.cshrc
(or ~/.tcshrc) or the system-wide /etc/csh.cshrc:

setenv GEM_HOME "$GEM_HOME"

################################################################################

EOF
exit 0

USERID=“id -ru
DFLTSHELL=“grep ':'$USERID':' /etc/passwd | head -1 | cut -d: -f7

PREFIX=“/tmp/$$”
$DFLTSHELL -c “export HOME && touch $PREFIX.sh || touch $PREFIX.csh”
2>/dev/null

if test -e $PREFIX.csh
then
cat <<-EOF >&2

Your shell seems to be a C shell derivative. Be sure to add the
following line to your ~/.cshrc (or ~/.tcshrc) and/or the
system-wide /etc/csh.cshrc:

setenv GEM_HOME "$GEM_HOME"

EOF
rm -f $PREFIX.csh

elif test -e $PREFIX.sh
then
cat <<-EOF >&2

Your shell seems to be a Bourne shell derivative. Be sure to add
the following lines to your ~/.profile and/or the system-wide
/etc/profile:

GEM_HOME="$GEM_HOME"
export GEM_HOME

EOF
rm -f $PREFIX.sh

else
cat <<-EOF >&2

Cannot determine your shell. Be sure to set the GEM_HOME
environment variable in your shell's init/config file to
'$GEM_HOME'

EOF

fi

I know that some people are going to cringe at the thought of this, but
my
company’s production server is hosted with rackspace, which uses RHEL.
Everything was pretty easy setting up except for the mysql gem was
giving me
segfaults, which was rackspace’s issue of not updating all the packages
that
they should have (I blogged about it at http://www.migrob.com). Overall
we
have been very pleased with the performance that we have been getting.
When
we write our rails applications we develop them locally, and run an svn
server on Kubuntu’s Dapper Drake RC 6 for the dev boxes and Kubuntu
Breezy
Badger for the svn server. Both have proven rock solid for us.

my $0.02

Rob

Will, I tried to get Apache working previously with Debian and
performance was horrible. This box was also serving PHP stuff. I
implemented Lighttpd and it works well, but I have some plesk driven
boxes that I would like to get an Apache solution going. So you would
recommend giving it another try?

Michael

I’ve been contemplating a move from Debian Sarge stable to either
Debian Unstable, Gentoo or FreeBSD for my workstations. I am thinking
of doing this in anticipation of ruby-1.8.4 being required for rails
development. (not yet but may be at 1.2?) I don’t think Sarge will be
upgraded to it any time soon, if at all. Gentoo seems great but the
initial build can be a pain.

The only question I have about FreeBSD is whether it plays well on
laptops and if so which ones. I did a bit of googling on the subject
and I don’t see any newer laptops on the list. I’d like to go with
coreduo with 667MHz RAM. Ofcourse an obvious option is the Macbook
Pro. I was a bit surprised to see that most good brand name coreduo
laptops with similar specs of a Macbook Pro are atleast as expensive.
I am very familiar with and addicted linux/emacs. apt-get(on Debian)
and all things Linux. So this can be painful transition both on my
pocket book and my psyche :slight_smile:

-bakki

Hi,

I’ve been doing development using Rails 1.0, 1.1.x, and Edge on Ubuntu
Dapper Drake. I did a dist-upgrade from Breezy Badger because the isos
weren’t released yet. Dapper now has a package for lighttpd (I’ve
installed it but haven’t used it yet). This is on a Dell Inspiron 5150
and the only special thing I needed was the windows driver for
ndiswrapper to get the wi-fi working. Everything else has worked, in a
word, like a charm.

In my experience with number of distros, for a personal laptop, Dapper
comes as close to using a mac as I’ve gotten.

Brian

Ruby 1.8.4 is extremely easy to compile and manage the install
especially
when using debian based systems and checkinstall
http://asic-linux.com.mx/~izto/checkinstall/

Rob

On Apr 21, 2006, at 8:51 AM, Bakki K. wrote:

O fcourse an obvious option is the Macbook
Pro. I was a bit surprised to see that most good brand name coreduo
laptops with similar specs of a Macbook Pro are atleast as expensive.
I am very familiar with and addicted linux/emacs.

OS X appears to ship with emacs built in:

GNU Emacs 21.2.1
Copyright © 2001 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.

And, there’s a system called DarwinPorts that is quite nice.

And, with BootCamp, if you don’t like OS X, you can keep your Mac
and install Linux.


– Tom M.

Rob,

I’ve been wondering about this. I had installed checkinstall-1.5.3-3
on my Sarge box which depends on Installwatch 0.6.3. The thing that
scared me and stopped me from compiling Ruby-1.8.4 was this bit in the
readme file …
“The Debian support in CheckInstall is still new, so handle it with
care. It has been reported to work OK in some Debian systems and it
certainly works OK in my Slackware development system”. I didn’t want
a broken Ruby.

The current version of checkinstall is 1.6.0. The site doesn’t say
anything about whether it still works with Installwatch0.6.3.

Would you please tell me what versions you’ve been using (I am
assuming that you have done this on Sarge).

Thanks,

bakki

Every time I see the Mac I do get tempted (I used to be a Mac
developer since 1984 till they almost went under) and all nostalgic
BUT once I get past all the eye candy I feel it is just as useful a
machine as any similar PC laptop with FreeBSD or LInux no more no
less.

-b

Except that a MacBook will run MacOS and a similar PC laptop
won’t :slight_smile: Also, the fact that MacBook Pros stand out between other
laptops because of their Aluminum look is good for your company’s
image. Add that to a Keynote presentation in a demo (just after
they’ve seen 10 blant PowerPoint standard template presentations) and
it can really give you the edge you need to get the order.

Best regards

Peter De Berdt

Tom,

It is certainly tempting but for the hefty price tag of the Mac.

While not identically equipped, there are coreduo laptops like the
HPdv8233cl at

which has the 1.66GHz coreduo but has 1GB 6678MHz RAM, two 100GB hard
drives (!!) which will let me have dual boot with XP on HD1 and Linux
or FreeBSD or whatever on HD2. It also has a gorgeous brightview 17"
1440x900 display, 6-in-1 card reader, ethernet + ABG wireless
etc…Lot of machine for about $1000 less than Macbook Pro. Weighs a
couple pounds more than the MacBookPro at 8.1 lbs.

Every time I see the Mac I do get tempted (I used to be a Mac
developer since 1984 till they almost went under) and all nostalgic
BUT once I get past all the eye candy I feel it is just as useful a
machine as any similar PC laptop with FreeBSD or LInux no more no
less.

-bakki

Peter,

I agree that Apple hires the best industrial designers out there and
their computers have always stood out and look great. I am still
pondering whether the MacbookPro is $1,000 more great :slight_smile:

-bakki

Bakki,

I did it with Kubuntu Breezy Badger a few months ago, and have installed
Dapper Drake since then which has a package for ruby 1.8.4. So
unfortunately I can’t look up the version of checkinstall that I was
using.
Sorry. So whatever version happens to be in the ubuntu repo’s worked
perfectly for me.

Rob

Gregory S. wrote:

} with mod_fcgi, mod_fcgid is working great.
don’t know how far that effort has gotten.
Check out this package

http://www.orcaware.com/packages/ubuntu/breezy/libgems-ruby1.8/

These were built on Ubuntu Breezy, but they should work on Debian.

It installs all the gems into /var/lib/gems and if you --purge it, it’ll
remove
the directory and all the gems.

Regards,
Blair


Blair Z., Ph.D.
[email protected]
Subversion training, consulting and support
http://www.orcaware.com/svn/

On Apr 21, 2006, at 8:51 AM, Bakki K. wrote:

O fcourse an obvious option is the Macbook Pro. I was a bit surprised
to see that most good brand name coreduo laptops with similar
specs of
a Macbook Pro are atleast as expensive.

On Apr 21, 2006, at 12:20 PM, Bakki K. wrote:

It is certainly tempting but for the hefty price tag of the Mac.

That’s an abrupt change of opinion in under 4 hours. :slight_smile:


– Tom M.

Oh, this is fast devaluation of electronic products !