Skip to content

Repository files navigation

WEBSITE : OpenPOWER Foundation

This repository is the source that builds the static front public website of the OpenPOWER Foundation.

Static Site

This repository is the source used by HugoCMS to build the OpenPOWER public facing website.

Testing the forms

The forms post to formsender, which creates tickets in the OpenPOWER Foundation RT. To see the ticket a form creates without sending one to RT, run a local formsender in DRY_RUN mode with Docker and serve the site in another terminal:

make formsender
make serve

Submit a form at http://localhost:1314/ and formsender writes the ticket it would have created (queue, subject, custom fields and body) to its log. The development config points the forms at it and uses Cloudflare's always-passing Turnstile test key. To test unreleased formsender changes, set FORMSENDER_SRC to a formsender checkout and it is built from there:

FORMSENDER_SRC=../formsender make formsender

Building

The theme needs Hugo 0.158 or newer (extended) and compiles its SCSS through an external Dart Sass binary on the PATH.

make build                  # production build into public/
make build HUGO_ENV=staging # forms point at an address that never resolves
make build DEST=/tmp/site   # build somewhere else

Continuous integration

GitHub Actions run on every pull request and on pushes to master:

  • Hugo Build Check builds the site with the staging environment, runs htmltest on the internal links and assets (.htmltest.yml) and checks the alias redirects. It also runs a WCAG 2.1 AA scan with pa11y-ci (.pa11yci.js), which is advisory for now.
  • Markdownlint Check is advisory for now; existing content doesn't pass yet. Prettier Check must pass, so run npm run format before committing.
  • PR Preview publishes each pull request from this repository to GitHub Pages at https://openpowerfoundation.github.io/website-openpower.foundation/pr-preview/pr-<N>/ and removes it when the PR closes. A few links that the theme hardcodes without the base URL point at the production site from a preview. Previews are built with the staging environment, so the forms can't create tickets.

Setup that needs a repo admin: enable GitHub Pages with the gh-pages branch as its source, and require the "Build, link check" job in the branch protection for master.

Deploying

Jenkins (a multibranch pipeline using the Jenkinsfile) runs on the opf1 agent. Pushes to master pull the checkout in /var/www/openpowerfoundation.org/website-openpower.foundation (fast-forward only, so a checkout with local changes fails the build), build the site into the workspace and rsync it into the docroot /var/www/openpowerfoundation.org/public. A failed build leaves the live site untouched. Other branches and pull requests only check that the site builds. The site_pr_builder credential is used for the GitHub status.

License

This repository has multiple open source licenses, all permissive.
Any logos, images, trademarks, specifications are property of their respective owners.
The OpenPOWER Foundation has registered trademarks and uses trademarks. For a list of trademarks of the OpenPOWER Foundation, please see our Trademark and Logo Usage Guidelines.

Releases

Packages

Contributors

Languages