Jekyll Icon

Intro

For a long time I have been trying to develop my own blog using something simple. I was tired of wordpress, didn’t want to develop a customer site using any other Technologies. Then one day one of my friends, out of nowhere, called me to see if I can resolve an issue that he was experiencing setting up a website. To my surprise he wasn’t using any of the frameworks that I know. He was using Jekyll. Next thing, I am down a rabbit hole, searching the web about Jekyll, finding themes about Jekyll, trying to setup Jekyll, anything and everything about Jekyll. I host my own website on Dreamhost and as such I needed an easier way to push my blog code to Dreamhost. After searching for a while I and reading few articles I was able to get it working. On this post I document that processes that I followed to get it up and working.

Prerequisites

  • Familiarity with terminal
  • Hosting on dreamhost

For finding out the version of your OS execute the following:

lsb_release -a

For me this is what came up:

[iad1-shared-d12-04]$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 18.04.6 LTS
Release:        18.04
Codename:       bionic

Here is an articles that has some handy commands to find out more about your dreamhost server.

Step 1: Install RVM

Install the gpg keys:

gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
  • Install rvm:
curl -sSL https://get.rvm.io | bash -s stable

Step 2: Install Ruby

Mount the binary using rvm. You can get the version for your OS and version here.

rvm mount -r https://rvm.io/binaries/ubuntu/18.04/x86_64/ruby-3.2.1.tar.bz2 --verify-downloads 1

Verify that ruby mount worked using:

rvm list

For me it shows something like the following:

ruby-3.2.1

Step 3: Create an alias

rvm alias create default ruby-3.2.1 (for you its going to be whatever version you installed)

Step 4: Initiate Default Ruby

rvm default

Step 5: Install Jekyll

gem install jekyll

Since you have set the default ruby version to be the one installed by you, everything should work.

You can verify that jekyll installed successfully by executing the following:

``jekyll --version``

Conclusion

Hope I was able to help you setup jekyll on your server. If you like this post, please don’t forget to share on Twitter. Don’t forget to tag me at @mdzahedhossain. Cheers!