This is the repository containing the Analytical Platform status page.
The static website is generated using Hugo a popular static website generator.
The Status Page use the cState which also provide the "issue" archetype.
On a Mac you can hugo by running brew install hugo
, alternatively you
can follow the installation instructions on the Hugo website.
cState is the theme used by the Status Page. The first time you clone the repository locally you'll have to pull the git submodule by running:
$ git pull --recurse-submodules
This needs to be done only the first time.
Incidents are simply Markdown files that are under content/issues/. They are formatted in such a way that cState can recognize the inputted data and generate your status page appropriately.
You can easily create a new issue by running the ./new-issue.sh
script:
$ ./new-issue.sh Upgrade Kubernetes cluster to v42
A new issue is been created at 'content/issues/2019-07-12-upgrade-kubernetes-cluster-to-v42.md'
**** IMPORTANT ****
- edit this file to add the details about the issue
- be sure the list of affected systems is correct
- be sure the severity is correct
- use the '$ hugo server' command to preview the Status Page
- use the '$ hugo' command to re-build the Status Page files
- add, commit and push the files in '/docs' once you're happy with the output
Then edit this newly created file updating the following fields as necessary:
title
, title of the issue, e.g. "DB Connection Issues"date
, ISO-8601 formatted date when the incident was first discovered - including the seconds. (required)resolved
, boolean,true
when an issue is resolvedresolvedWhen
, date when the issue was resolved (required ifresolved
istrue
!)severity
, can benotice
,disrupted
ordown
(from lower to higher severity)affected
, list of systems affected, e.g.Control Panel
orKubernetes Cluster
section
, is alwaysissue
(don't change it)published
, boolean which determine if the incident page is published
The details of the incident will go under ---
(there are some
example issues under content/issues/
).
Note the use of the {{< track "2019-01-01 15:56:00" >}}
shortcode which
will be displayed nicely in the rendered page - just remember to include
the seconds.
Also see: cState documentation on creating a new incident.
You can see how the Status Page will look like by running the Hugo server locally.
From the toplevel directory run the following command:
$ hugo server
Then go to http://localhost:1313/ in your browser (or at whatever URL/port Hugo will run at).
The Status Page is hosted on GitHub Pages at https://ministryofjustice.github.io/analytics-platform-status-page/
The repository is configured to serve files from /docs
.
That's why /config.yml
contains the publishDir: "docs"
option.
To update the Status Page
- rebuild the static website by runnng
hugo
- commit the changes and push to the
master
branch - this could take a brief period of time to update the Status Page.
The "issue" archetype is just a custom page type with the following attributes:
Systems are high level (ish) components. Users may want to know if these are operational or not.
At the moment we only have the following Systems:
Control Panel
Kubernetes Cluster
We may want to add more or tweak the description. This can be done
updating the params.systems
configuration in the /config.yml
file if necessary.
NOTE: When using these in the affected
field of an issue be sure
that the case is the same.
Custom Tabs are shown in the page and we use them to link to the status pages of the following services:
- Auth0
- AWS
- GitHub
Again, if necessary this list can be changed by changing the customTabs
configuration in the /config.yml
file.
For additional information you can look at the cState wiki at https://github.com/cstate/cstate/wiki