Static sites

with Pelican

Quality coding #3

Dan Fitch

2020-10-07

Why static?

What does it mean?

No code running on the web server

No database

Just a pile of HTML files like the olden days

The main goal: separate style from content
There are different tools: Jekyll, Hugo, Pelican, etc.
Markdown is simpler to write than HTML5

Installing pelican

pip install pelican[markdown]

mkdir -p ~/projects/website

cd ~/projects/website

pelican-quickstart

Edit your site

Create ./content/about.md

Create ./content/test-post.md

pelican content --relative-urls

Open up output/index.html

Putting your site on the BI servers

Drag and drop over shared drive

Make a folder in your home directory called pub_html

Plop the files from the pelican output/ directory there

OR

scp (or pscp)

ssh login.keck.waisman.wisc.edu

scp -r output/* USERNAME@login.keck.waisman.wisc.edu:pub_html

See it!

https://brainimaging.waisman.wisc.edu/USERNAME

Customize your site

THE END

(discussion)

wheeeeee