Static site generator for website to track BT InLink kiosks planning applications.
How to build this site locally
Setup - do this only once
$ git clone email@example.com:adrianshort/kiosks.git && cd kiosks
$ bundle install
- Sign in to Morph with your GitHub account.
- Go to your Settings page: https://morph.io/owners/YOUR-USERNAME/settings and copy your secret API key.
$ export MORPH_API_KEY=123456abcdef(use the actual key value given)
MORPH_API_KEY to your
.bash_profile file or similar as required so it's available for every shell session.
Build - do this every time
$ bundle exec bin/download- gets the latest data from the scraper's API
$ bundle exec bin/build- builds the static site
The built site is now in the
If you've got build/deploy to Netlify set up (see below), use
[skip ci] in your commit messages to avoid triggering a build every time you
How to build and deploy this site on Netlify
Use Morph to send a webhook HTTP POST request to Netlify, triggering Netlify to build and deploy the site using the latest version of the data.
- Sign in to Netlify.
New site from Git
- Connect your GitHub account.
- Choose the
adrianshort/kiosksrepo to deploy, or your own fork of it.
- Use these settings: Branch to deploy:
master, build command:
bundle exec bin/download && bundle exec bin/build, publish directory:
Show advancedand create a
123456abcdef(use the actual key value given by Morph)
Deploy. Netlify will now build and deploy the site.
Set up a webhook to trigger automatic builds/deploys when the scraper finishes
Site settingsfor your Netlify site.
Build & deploytab >
Add build hook.
Build hook namecan be anything you like, eg
Morph scrape completed.
Branch to buildis
- Copy the webhook URL, eg:
- On Morph, go to the Settings page for your scraper.
- Paste the webhook URL and click
Netlify will now build and deploy the site using the latest scraper data every time the Morph scrape succeeds.