I (rather obviously) recently found myself attempting to install Octopress. Sure, it has great documentation, but some areas were lacking – specifically, initial setup. As someone who has not worked with Ruby before other than a rather limited Windows install for a jekyll project, I had virtually no experience installing Ruby, using RVM, or even playing with RubyGems.
After a couple of hours of trial and error (and Google-searching), I managed to get Octopress running on my local machine. I then proceeded to duplicate my steps on my other dev machine; wonder of wonders, it became a simple five-minute process once I knew what to do.
As I stated earlier, the Octopress documentation doesn’t cover everything, so I figured I’d go over my install process in more detail here to help you get started with Octopress and its underlying technologies.
According to the RVM guide, you need a few prerequisites to install Ruby:
Feel free to disregard some of the packages in the second command if you know better; I haven’t verified whether all of them are absolutely necessary.
Also, a quick disclaimer: I am by no means an expert in this. This is the tale of one man’s successful fight to install Octopress, and as such, I cannot address all of the variants of installations. I’m not using Github Pages, so I won’t specifically address that (the Octopress guide goes over Github Pages integration with much detail). My two installs both used Ubuntu-derived distributions, so I’m guessing these instructions will mostly work for Debian-based systems. No guarantees beyond that. I installed RVM for single-user use; system-wide installation instructions can be found in the RVM guide if you need them.
RVM is the Ruby Version Manager. It handles the installation and management of multiple Ruby environments, and Octopress was created specifically to be installed into an RVM-controlled environment.
Start off with this command to install single-user RVM (for system-wide installation instructions, see the RVM guide):
Once RVM is installed, tell bash to use it (you only need to do this once):
To check that it is properly installed, run one (or both) of these commands:
1 2 3 4
Installing OpenSSL & iconv
Now that you’ve installed RVM, you should use it to install the OpenSSL & iconv packages. They are used within Octopress, so they must be installed and correctly integrated with Ruby.
Run these commands to install the two:
This step is the meat of the process. You must install version
1.9.2 of Ruby. It may take a while to download and install, but after it has finished, you will have a fresh copy of the newest Ruby release installed into RVM.
Once Ruby is installed, ensure RVM has also installed the latest RubyGems:
Finally, tell RVM to use
1.9.2 as the default Ruby and install the Bundler dependency manager:
1 2 3
Getting Started With Octopress
Now that you have the system all configured, you’re almost all ready to begin the Octopress setup. Simply change directories to a suitable location for your site repository and then follow the instructions on the Octopress Setup Page. The Octopress docs should be able to answer pretty much any further questions you have about installing, configuring, or blogging with Octopress; they are quite extensive.
I hope this simple guide was helpful. If you have any questions or comments, let me know! Shoot me an email at firstname.lastname@example.org or post in the comments below (assuming I’ve gotten Disqus to work). Thanks for stopping by.