Welcome to the upptime-backend backend plugin!
This plugin needs to be added to an existing backstage instance.
# From your Backstage root directory
yarn add --cwd packages/backend @philips-software/backstage-plugin-upptime-backend
You can then add the follwoing to your backend configuration in backend/src/index.ts
:
backend.add(import('@philips-software/backstage-plugin-upptime-backend'));
This plugin allows configuration of either a single or multiple global Upptime repository instances and annotating entities with the instance name. This instance name in the entities is optional, if not provided the default instance in configuration will be used. That allow to keep configuration from before multiple instances capability to keep working without changes.
Config
upptime:
locations:
default:
url: https://github.com/upptime/upptime/
Catalog file
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
name: backstage
annotations:
upptime.js.org/key: YOUR_PROJECT_KEY
The following will look for status at https://github.com/your-otg/status/
for
the project of key specialProject
.
Config
upptime:
instances:
default:
url: https://github.com/upptime/upptime/
specialProject:
url: https://github.com/your-otg/status
Catalog file
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
name: backstage
annotations:
upptime.js.org/key: specialProject/YOUR_PROJECT_KEY
If the specialProject/
part is omitted (or replaced with default/
), the
instance of name default
will be used.