Two great hosts for Ruby on Rails are Slicehost and Linode. With these hosts you fully manager your virtual private server, installing the operating system, modifying apache (on Ning…), etc.. I use Ubuntu as the operating system and Apache as the web server.
If you are moving a domain from elsewhere it can be wise to reduce the TTL time to say 5 minutes a few days before you make the switch. This is make the change propagate across the internet more quickly.
- And DNS entry on your profile (login to your, for example, Linode account)
- Add a new file for /etc/apache2/sites-available/your_site_name.com
- create the directories needed on your server
- enable the site (for apache)
[bash]sudo a2ensite example.com[/bash]
- Test the site out to make sure the setup is working properly. Create a index.html page and just verify the page is displayed. Change your local hosts file to point to your server IP address for the new domain you created. If not, take steps to get this to work, before continuing with the rest of the checklist.
- copy over the site – if you are moving the site from elsewhere
- remember to move the database over, if the site relies on a database
- restart apache
[bash]sudo /etc/init.d/apache2 restart[/bash]
[bash]sudo nano /etc/apache2/sites-available/example.com[/bash]
The file would look something like this: with your ip in place of 188.8.131.52
ServerAdmin is the address Apache will use to send error messages to. Using gmail and the + option lets you use one gmail account and just use rules to filter all your sites.
You should see the file you created /etc/apache2/sites-available/example.com now also at /etc/apache2/sites-enabled/example.com
You can test the site out, before updating the DNS, by changing your local hosts file to point to your server IP address for the new domain you created.
Resources: Install the Apache 2 Web Server on Ubuntu 10.04 LTS (Lucid)
Pingback: Wordpress: Multiple Blog Network on One Server – Overcoming Conflicts | Coding and Server Syntax Examples
Pingback: Set the Web Server to Use the Domain Without www | Coding and Server Syntax Examples
Pingback: Upgrading VPS Web Server from Ubuntu 10.04 to 12.04 | Coding and Server Syntax Examples
Pingback: Updates Needed When Upgrading from Apache 2.2 to 2.4 | Coding and Server Syntax Examples
Pingback: How to Manually Run Cron Tasks | Coding and Server Syntax Examples