Ubuntu 10.04 setup for Ruby on Rails and general use
This extract is from notes I took during the process of setting up both a desktop and laptop for general use as a development environment for Ruby on Rails (RoR) and PHP development.
There were lots of other steps (custom gems and environment stuff I like), but most of what follows is generic enough to get the basics in place. Happy Hacking!!
Installing Skype
sudo dpkg -i skype-ubuntu-intrepid_2.1.0.81-1_amd64.deb
Installing Amarok
To get remote shares mapping in fstab.
Firstly, install the smb client package
sudo apt-get install portmap nfs-common
Then add the following line to /etc/hosts.deny:
By blocking all clients first, only clients in /etc/hosts.allow below will be allowed to access the server.
Now add the following line to /etc/hosts.allow. User your own IP address.
Next create the mounting points on your system
sudo mkdir /mnt/music
sudo mkdir /mnt/backups
Create a file in home folder called .smbcredentials (note the leading dot)
echo username=[your network username] >> ~/.smbcredentials
echo password=[your network password] >> ~/.smbcredentials
chmod 600 ~/.smbcredentials
Now an entry in /etc/fstab using the ip address of your NAS
#Note: everything that follows (up to the 0 0 should appear on the one line)
#and one line is required for each share you want to map
//192.168.0.20/<foldername on NAS> /mnt/<local foldername> cifs
uid=peter,credentials=/home/peter/.smbcredentials,domain=office,dir_mode=0777,file_mode=0777 0 0
Now, for a few of the other standard tools
Setup filezilla and limewire
#Limewire - download LimeWireLinux.deb from limewire site
# reports missing dependencies
sudo dpkg -i LimeWireLinux.deb
limewire-basic depends on sun-java6-jre | icedtea-java7-jre |
sun-java6-jdk | icedtea-java7-jdk; however:
Package sun-java6-jre is not installed.
Package icedtea-java7-jre is not installed.
Package sun-java6-jdk is not installed.
Package icedtea-java7-jdk is not installed.
dpkg: error processing limewire-basic (--install):
dependency problems - leaving unconfigured
Open synaptic package manager. Go to the Settings/Repositories/Other sources tab.
Check the two default partner sites. Reload the package list and select the following
sun-java6-jre
sun-java6-plugin
sun-java6-fonts packages
Now retry limewire and you’re smoking.
Installing ruby and associated gems
sudo apt-get install rubygems
sudo gem install rake
sudo gem install rails
I tried to install capistrano using sudo but it wasn’t working on laptop however it did work on desktop
Then change ~/.bashrc to include path to new gems
export PATH=$PATH:~/.gem/ruby/1.8/bin:/var/lib/gems/1.8/bin
Now install and configure mysql before trying to install any of the ruby mysql gems
sudo apt-get install mysql-server
Setup prompts you for a password – enter it, remember it and enter it again.
Install the mysql admin tools
NB – must install the libmysqlclient[nn]-dev package
This has mysql_config bundled with it which is needed by the ruby gems
Execute the following to find out what version of libmysqlclient you’re running
In my case it’s version 16, so execute the following
Next, you NEED TO INSTALL the ruby1.8 dev package
If you don’t you’ll get all sorts of mysql gem errors — frustrating!!!
sudo gem install mysql
Installing and configuring git
git config --global user.email
Installing apache
The line above should do it, if you get any glitches, try the following
sudo apt-get install apache2.2-common
sudo apt-get install apache2-threaded-dev
Installing php
sudo apt-get install php5-mysql
Anything else is stuffing around with particular ruby gems and dev tools so probably too specific for this note.


No Responses to “Ubuntu 10.04 setup for Ruby on Rails and general use”
Leave a Reply