Installing Jekyll on Fedora 30

1 minute read

Introduction

Jekyll is simple static site generator that focuses on blogs, but can be used for all kinds of sites. It takes html templates and posts written in Markdown to generate static website which is ready to deploy on your favorite web server. Alternatively you can host it on GitHub and publish it via GitHub Pages, absolutely for free.

I use Jekyll for my blog. And official instruction doesn’t enough for me. I got some issues, really small things, and the most one is a Jekyll error. Trying to install Jekyll on the new machine, I got a error.

I need some package installed because some version of ruby binary are not available for Fedora.

Environment

In this article I use next version of installed components:

  1. Fedora 30
  2. ruby 2.6.3p62 (2019-04-16 revision 67580)

Installation

dnf install

I install next packages manually. It will pretty enough to install Jekyll.

sudo dnf install ruby ruby-devel rubygems-devel \
                 autoconf automake bison gcc-c++ libffi-devel libtool \
                 libyaml-devel readline-devel sqlite-devel zlib-devel \
                 openssl-devel redhat-rpm-config rubygem-nokogiri

So I am not sure that all of them are needed.

update system

Update all system gems

sudo gem install rubygems-update

Then run it

sudo gem update --system

or (if previous not work)

sudo gem update --system --install-dir=/usr/share/gems --bindir /usr/local/bin

install jekyll

Next, install gems for Jekyll and Bundler

sudo gem install jekyll bundler

Done! You may install new Jekyll site and test it locally :)

Some notes

Inside Jekyll project directory, run bundler install and bundler update --bundler to install and update the gems needed, then use bundle exec jekyll serve -d public --incremental --verbose --watch to run Jekyll on localhost. If success open URL:localhost:4000 in browser.

Additional information