Skip to content

Repository files navigation

Jekyll Static Website Source for Doctor's Landing Page

Build Status Bugs Technical Debt Maintainability Rating

This is the source for the Jekyll static website project for a very simple doctors landing page. The production version can be found here.

website screenshot

Build

Jekyll is a Ruby CLI used to build the static site.

Ruby

Jekyll requires Ruby 2.6+ so you might be required to install it.

Install Ruby itself:

apt-get update
apt-get install ruby-full
apt-get install nodejs

Install rbenv for easier switching of ruby versions by following this guide then install the desired ruby version:

# will read .ruby-version file and install the required version if in the root of the repo
rbenv install
# set global version to the one in .ruby-version
rbenv global $(cat .ruby-version)

ruby -v

Then update the gems (Ruby package manager)

gem update

For details on how to do this on the Linux subsystem for Windows 10 see here.

Bundler and Jekyll

Install the bundler:

gem install bundler

you may want to set the default gem path, so you don't need sudo

bundle config set path vendor/bundle

then, in the project root folder, install all the dependencies with

bundle install

You should be able to run jekyll now with

bundle exec jekyll -v

Develop

With this command a development web-server will be started on http://localhost:4000

bundle exec jekyll serve --livereload

For more info see the quick-start section.

Build Site

With the following command the website will be packaged and copied to _site

bundle exec jekyll build

Continuous Deployment

Every pull request is built and checked with HTMLProofer. Pull requests do not deploy the Worker.

Every commit on main is built with the production configuration and deployed to a Cloudflare Worker through GitHub Actions.

First-time Cloudflare setup

The repository uses Wrangler static-asset deployments, so create the Worker before the first deployment:

  1. In Cloudflare, open Workers & Pages, choose Create applicationWorkers, and create a Worker named website-dr-sel. Enable its workers.dev and preview URLs if prompted.
  2. Create a scoped Cloudflare API token using the Edit Cloudflare Workers permission.
  3. In the GitHub repository, add these Actions secrets under Settings → Secrets and variables → Actions: CLOUDFLARE_ACCOUNT_ID and CLOUDFLARE_API_TOKEN.
  4. Add selwicka-wienerroither.com as a custom domain for the Worker. The domain's nameservers must be managed by Cloudflare.

The build runs in GitHub Actions and wrangler.jsonc deploys the Worker and uploads _site/; no separate dashboard build command is required.

Frameworks and Libraries

License

Proprietary: Patrick Favre-Bulle 2018

About

A simple static website created with jekyll

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Used by

Contributors

Languages