Skip to content
This repository has been archived by the owner on Jul 12, 2024. It is now read-only.

appuio/website

Repository files navigation

APPUiO.ch website

Local development

To start an auto-reloading local server:

docker run --rm -v $(pwd):/src -p 1313:1313 klakegg/hugo:ext-alpine server

Then open http://localhost:1313 in your browser. Whenever you save a file the website in the browser reloads.

Installation

oc create sa github-workflow
oc policy add-role-to-user admin -z github-workflow
oc sa get-token github-workflow

Add the token to the secret OPENSHIFT_TOKEN

Secrets

The following secrets must be configured:

  • OPENSHIFT_TOKEN
  • OAUTH_CLIENT_ID Github Oauth App for CMS
  • OAUTH_CLIENT_SECRET

Open Issues

indentation in partial/shortcode wrapped in <pre><code>
Workaround: use {{- -}} everywhere and remove all empty lines

Shortcodes are not reloading when inner resources are changed
Workaround: restart hugo serve after changes

Unclosed shortcode uses rest of page as .Inner ({{<shortcode>}} vs {{<shortcode/>}})
Workaround: be careful

Non-closing shortcodes with .Inner use the rest of the page instead of throwing an error
Workaround: count the opening and closing tags and throw an error if not the same. Add shortcode to mustCloseShortcodes in config.toml. themes/appuio/layouts/partials/check-must-close-shortcodes.html.
TODO: report issue to Hugo or create pull request