Files
backstage/plugins/kubernetes
Matthew Clarke 5a9a7e7c26 Kubernetes plugin: UI revamp (#3918)
* initial revamp, no error reporting

* initial error detection

* more error detection

* add microsite page

* minor fixes

* add HPA error detection

* refactor error reporting; add tests

* fix import

* add changeseet

* empty error state

* prettier yaml file

* Update plugins/kubernetes/src/components/KubernetesDrawer/KubernetesDrawer.tsx

Co-authored-by: Patrik Oldsberg <poldsberg@gmail.com>

* Update plugins/kubernetes/src/components/KubernetesDrawer/KubernetesDrawer.tsx

Co-authored-by: Patrik Oldsberg <poldsberg@gmail.com>

* PR feedback

* revert odd change

* make patch change

* fix test

* Apply suggestions from code review

Co-authored-by: Fredrik Adelöw <freben@gmail.com>

* prettier

* pr feedback

Co-authored-by: Patrik Oldsberg <poldsberg@gmail.com>
Co-authored-by: Fredrik Adelöw <freben@gmail.com>
2021-01-11 16:50:30 +00:00
..
2021-01-11 16:50:30 +00:00
2020-12-17 10:16:33 +00:00

kubernetes

Welcome to the kubernetes plugin!

This plugin was created through the Backstage CLI

Getting started

Your plugin has been added to the example app in this repository, meaning you'll be able to access it by running yarn start in the root directory, and then navigating to /kubernetes.

You can also serve the plugin in isolation by running yarn start in the plugin directory. This method of serving the plugin provides quicker iteration speed and a faster startup and hot reloads. It is only meant for local development, and the setup for it can be found inside the /dev directory.

Surfacing your Kubernetes components as part of an entity

There are two ways to surface your kubernetes components as part of an entity. The label selector takes precedence over the annotation/service id.

Common backstage.io/kubernetes-id label

Adding the entity annotation

In order for Backstage to detect that an entity has Kubernetes components, the following annotation should be added to the entity.

annotations:
  'backstage.io/kubernetes-id': dice-roller

Labeling Kubernetes components

In order for Kubernetes components to show up in the service catalog as a part of an entity, Kubernetes components must be labeled with the following label:

'backstage.io/kubernetes-id': <ENTITY_NAME>

label selector query annotation

Adding a label selector query annotation

You can write your own custom label selector query that backstage will use to lookup the objects (similar to kubectl --selector="your query here") review the documentation here for more info

'backstage.io/kubernetes-label-selector': 'app=my-app,component=front-end'