Merge branch 'backstage:master' into master

This commit is contained in:
Hannes Jetter
2023-10-19 08:51:45 +02:00
committed by GitHub
1292 changed files with 34468 additions and 11267 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 142 KiB

Before

Width:  |  Height:  |  Size: 293 KiB

After

Width:  |  Height:  |  Size: 293 KiB

@@ -44,6 +44,20 @@ When multiple `catalog-info.yaml` files with the same `metadata.name` property
are discovered, one will be processed and all others will be skipped. This
action is logged for further investigation.
### Local File (`type: file`) Configurations
In addition to url locations, you can use the `file` location type to bring in content from the local file system. You should only use this for local development, test setups and example data, not for production data.
You are also not able to use placeholders in them like `$text`. You can however reference other files relative to the current file. See the full [catalog example data set here](https://github.com/backstage/backstage/tree/master/packages/catalog-model/examples) for an extensive example.
Here is an example pulling in the `all.yaml` file from the examples folder. Note the use of `../../` to go up two levels from the current execution path of the backend. This is typically `packages/backend/`.
```yaml
catalog:
locations:
- type: file
target: ../../examples/all.yaml
```
### Integration Processors
Integrations may simply provide a mechanism to handle `url` location type for an
@@ -447,6 +447,9 @@ want to have an isomorphic package that houses these types. Within the Backstage
main repo the package naming pattern of `<plugin>-common` is used for isomorphic
packages, and you may choose to adopt this pattern as well.
You can generate an isomorphic plugin package by running:`yarn new --select plugin-common`
or you can run `yarn new` and then select "plugin-common" from the list of options
There's at this point no existing templates for generating isomorphic plugins
using the `@backstage/cli`. Perhaps the simplest wat to get started right now is
to copy the contents of one of the existing packages in the main repository,
@@ -110,10 +110,11 @@ parameters:
arrayObjects:
title: Array with custom objects
type: array
minItems: 0
ui:options:
addable: false
orderable: false
removable: false
addable: true
orderable: true
removable: true
items:
type: object
properties:
+1
View File
@@ -95,6 +95,7 @@ Options:
--preview-app-bundle-path <PATH_TO_BUNDLE> Preview documentation using a web app other than the included one.
--preview-app-port <PORT> Port where the preview will be served.
Can only be used with "--preview-app-bundle-path". (default: "3000")
-c, --mkdocs-config-file-name <FILENAME> Yaml file to use as config by mkdocs.
-v --verbose Enable verbose output. (default: false)
-h, --help display help for command
```
+33
View File
@@ -525,6 +525,39 @@ techdocs:
This way, all iframes where the host in the src attribute is in the
`sanitizer.allowedIframeHosts` list will be displayed.
## How to render PlantUML diagram in TechDocs
PlantUML allows you to create diagrams from plain text language. Each diagram description begins with the keyword - (@startXYZ and @endXYZ, depending on the kind of diagram). For UML Diagrams, Keywords @startuml & @enduml should be used. Further details for all types of diagrams can be found at [PlantUML Language Reference Guide](https://plantuml.com/guide).
### UML Diagram Details:-
#### Embedded PlantUML Diagram Example
Here, the markdown file itself contains the diagram description.
````md
```plantuml
@startuml
title Login Sequence
ComponentA->ComponentB: Login Request
note right of ComponentB: ComponentB logs message
ComponentB->ComponentA: Login Response
@enduml
```
````
#### Referenced PlantUML Diagram Example
Here, the markdown file refers to another file (`*.puml` or `*.pu`) which contains the diagram description.
````md
```plantuml
!include umldiagram.puml
```
````
Note: To refer external diagram files, we need to include the diagrams directory in the path. Please refer [`Dockerfile`](https://github.com/backstage/techdocs-container/blob/main/Dockerfile) for details.
## How to add Mermaid support in TechDocs
To add `Mermaid` support in TechDocs, you can use [`kroki`](https://kroki.io)
+23 -24
View File
@@ -484,30 +484,29 @@ of the build system, including the bundling, tests, builds, and type checking.
Loaders are always selected based on the file extension. The following is a list
of all supported file extensions:
| Extension | Exports | Purpose |
| ----------- | --------------- | -------------------------------------------------------------------------------------- |
| `.ts` | Script Module | TypeScript |
| `.tsx` | Script Module | TypeScript and XML |
| `.js` | Script Module | JavaScript |
| `.jsx` | Script Module | JavaScript and XML |
| `.mjs` | Script Module | ECMAScript Module |
| `.cjs` | Script Module | CommonJS Module |
| `.json` | JSON Data | JSON Data |
| `.yml` | JSON Data | YAML Data |
| `.yaml` | JSON Data | YAML Data |
| `.css` | classes | Style sheet |
| `.eot` | URL Path | Font |
| `.ttf` | URL Path | Font |
| `.woff2` | URL Path | Font |
| `.woff` | URL Path | Font |
| `.bmp` | URL Path | Image |
| `.gif` | URL Path | Image |
| `.jpeg` | URL Path | Image |
| `.jpg` | URL Path | Image |
| `.png` | URL Path | Image |
| `.svg` | URL Path | Image |
| `.md` | URL Path | Markdown File |
| `.icon.svg` | React Component | SVG converted into a [Material UI SvgIcon](https://mui.com/material-ui/icons/#svgicon) |
| Extension | Exports | Purpose |
| --------- | ------------- | ------------------ |
| `.ts` | Script Module | TypeScript |
| `.tsx` | Script Module | TypeScript and XML |
| `.js` | Script Module | JavaScript |
| `.jsx` | Script Module | JavaScript and XML |
| `.mjs` | Script Module | ECMAScript Module |
| `.cjs` | Script Module | CommonJS Module |
| `.json` | JSON Data | JSON Data |
| `.yml` | JSON Data | YAML Data |
| `.yaml` | JSON Data | YAML Data |
| `.css` | classes | Style sheet |
| `.eot` | URL Path | Font |
| `.ttf` | URL Path | Font |
| `.woff2` | URL Path | Font |
| `.woff` | URL Path | Font |
| `.bmp` | URL Path | Image |
| `.gif` | URL Path | Image |
| `.jpeg` | URL Path | Image |
| `.jpg` | URL Path | Image |
| `.png` | URL Path | Image |
| `.svg` | URL Path | Image |
| `.md` | URL Path | Markdown File |
## Jest Configuration
+3
View File
@@ -323,8 +323,11 @@ backend:
cache:
store: redis
connection: redis://user:pass@cache.example.com:6379
useRedisSets: true
```
The useRedisSets flag is explained [here](https://github.com/jaredwray/keyv/tree/main/packages/redis#useredissets).
Contributions supporting other cache stores are welcome!
## Containerization
+11 -3
View File
@@ -8,7 +8,7 @@ A Backstage Plugin adds functionality to Backstage.
## Create a Plugin
To create a new plugin, make sure you've run `yarn install` and installed
To create a new frontend plugin, make sure you've run `yarn install` and installed
dependencies, then run the following on your command line (a shortcut to
invoking the
[`backstage-cli new --select plugin`](../local-dev/cli-commands.md#new))
@@ -18,7 +18,7 @@ from the root of your project.
yarn new --select plugin
```
![](../assets/getting-started/create-plugin_output.png)
![Example of output when creating a new plugin](../assets/getting-started/create-plugin_output.png)
This will create a new Backstage Plugin based on the ID that was provided. It
will be built and added to the Backstage App automatically.
@@ -27,7 +27,7 @@ will be built and added to the Backstage App automatically.
> should be able to see the default page for your new plugin directly by
> navigating to `http://localhost:3000/my-plugin`.
![](../assets/my-plugin_screenshot.png)
![Example of new plugin running in browser](../assets/plugins/my-plugin_screenshot.png)
You can also serve the plugin in isolation by running `yarn start` in the plugin
directory. Or by using the yarn workspace command, for example:
@@ -39,3 +39,11 @@ yarn workspace @backstage/plugin-my-plugin start # Also supports --check
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 plugin's `dev/` directory.
### Other Plugin Library Package Types
There are other plugin library package types that you can chose from. To be able to
select the type when you create a new plugin just run: `yarn new`. You'll then be asked
what type of plugin you wish to create like this:
![List of available plugin types to pick from](../assets/plugins/create-plugin_types.png)
+1 -1
View File
@@ -12,7 +12,7 @@ development tool as a plugin in Backstage. By following strong
[design guidelines](../dls/design.md) we ensure the overall user experience
stays consistent between plugins.
![plugin](../assets/my-plugin_screenshot.png)
![plugin](../assets/plugins/my-plugin_screenshot.png)
## Creating a plugin
+1 -1
View File
@@ -40,7 +40,7 @@ Congratulations on the release! There should be now a post in the [`#announcemen
Additional steps for the main line release
- [Switch Release Mode](#switching-release-modes) to exit pre-release mode. This can be done at any time after the last Next Line Release.
- Check [`.changeset/pre.json`](https://github.com/backstage/backstage/blob/master/.changeset/pre.json) if the `mode` is set to `exit`. If you encounter `mode: "pre"` it indicates a next line release.
- Check `.changeset/pre.json` <!-- do not link to pre.json, it breaks the build when it doesn't exist --> if the `mode` is set to `exit`. If you encounter `mode: "pre"` it indicates a next line release.
- Check [`Version Packages` Pull Request](https://github.com/backstage/backstage/pulls?q=is%3Aopen+is%3Apr+in%3Atitle+%22Version+Packages)
- Check for mentions of "major" & "breaking" and if they are expected in the current release
- Verify the version we are shipping is correct
+1 -1
View File
@@ -12,7 +12,7 @@ A huge thanks to the whole team of maintainers and contributors as well as the a
### <title>
<short description>. Contributed by [@<user>](https://github.com/<user>) [#<pr>](https://github.com/backstage/backstage/pull/<pr>)
<short description>. Contributed by [@<user>](https://github.com/<user>) in [#<pr>](https://github.com/backstage/backstage/pull/<pr>)
## Security Fixes
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -4,7 +4,7 @@
### Minor Changes
- 7077dbf131: The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior, set `LEGACY_BACKEND_START` instead.
- 7077dbf131: **BREAKING** The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior set `LEGACY_BACKEND_START`, which is recommended if you haven't migrated to the new backend system.
This new command is no longer based on Webpack, but instead uses Node.js loaders to transpile on the fly. Rather than hot reloading modules the entire backend is now restarted on change, but the SQLite database state is still maintained across restarts via a parent process.
File diff suppressed because it is too large Load Diff
+86
View File
@@ -0,0 +1,86 @@
---
id: v1.19.0
title: v1.19.0
description: Backstage Release v1.19.0
---
These are the release notes for the v1.19.0 release of [Backstage](https://backstage.io/).
A huge thanks to the whole team of maintainers and contributors as well as the amazing Backstage Community for the hard work in getting this release developed and done.
## Highlights
### Node.js v18 + v20
The supported versions of Node.js are now v18 and v20. Be sure to update the `engine` field in your root `package.json` accordingly and update your Dockerfile base images, for example to `node:18-bookworm-slim`.
### New default `start` command for backends
Backend packages now use the new `package start` implementation by default. This new version uses module loaders rather than a Webpack build for transpilation. The largest difference from the old version is that the backend process is now restarted on change, rather than using Webpack hot module reloads. When using SQLite the database state is serialized and stored in the parent process across restart, which requires a [migration to the new backend system](https://backstage.io/docs/backend-system/building-backends/migrating). If you have yet to migrate to the new system it is recommended that you set the `LEGACY_BACKEND_START` environment variable when starting the backend to keep the old behavior.
### **BREAKING**: Allow passing undefined `labelSelector` to `KubernetesFetcher`
`KubernetesFetch` no longer auto-adds `labelSelector` when an empty string is passed.
This is only applicable if you have a custom ObjectProvider implementation, as build-in `KubernetesFanOutHandler` already does this.
Contributed by [@szubster](https://github.com/szubster) in [#20541](https://github.com/backstage/backstage/pull/20541)
### **DEPRECATION**: Catalog GraphQL Backend Package
This package has been deprecated, consider using [@frontside/backstage-plugin-graphql-backend](https://www.npmjs.com/package/@frontside/backstage-plugin-graphql-backend) instead.
### **DEPRECATION**: `.icon.svg` Extension Support
Support for the `.icon.svg` extension has been deprecated and will be removed in a future release. Please migrate existing usage to either inline the SVG elements in a `<SvgIcon>` component from MUI, or switch to a regular `.svg` asset import.
### Insightful Homepage
You can now create an Insightful homepage to show your users their recent and top visited activity in Backstage. Add [this](https://github.com/backstage/backstage/tree/master/plugins/home#page-visit-homepage-component-homepagetopvisited--homepagerecentlyvisited) plugin to track your users recent navigation history in your Backstage database and display it in the Backstage Homepage using the customizable Recent and Top visits components (`<HomePageTopVisited />` and `<HomePageRecentlyVisited />`)and the extensible Visits API interface. This feature is released with an example that extends the Visits API with LocalStorage as an alternative storage solution for user visit activity.
### New plugin: Kubernetes Clusters
This plugin lets you view Kubernetes clusters as an admin.
### New feature: New Pinniped Auth Provider Module
This module provides a Pinniped auth provider implementation for the auth backend.
Contributed by [@RubenV-dev](https://github.com/RubenV-dev) in [#19846](https://github.com/backstage/backstage/pull/19846)
## More Movement Toward the New Backend System
Since the last release, a lot of contributions have been made toward migrating features to support [the new backend system](https://backstage.io/docs/backend-system/).
The following backend plugins were migrated:
- jenkins
- nomad
- sonarqube
- playlist
The Kubernetes backend broadened its backend system feature set, with a new extension point. For the catalog backend, some new modules were added, including GitHub org and Microsoft/Azure.
If you would like to help out with these efforts, check out [this issue](https://github.com/backstage/backstage/issues/18301)!
## Security Fixes
Some improvements were made in the configuration schemas, ensuring that no secret fields could be read outside of a backend context.
The `lerna` package in newly scaffolded Backstage repositories is now of version >7 which has security fixes.
## Upgrade path
We recommend that you keep your Backstage project up to date with this latest release. For more guidance on how to upgrade, check out the documentation for [keeping Backstage updated](https://backstage.io/docs/getting-started/keeping-backstage-updated).
## Links and References
Below you can find a list of links and references to help you learn about and start using this new release.
- [Backstage official website](https://backstage.io/), [documentation](https://backstage.io/docs/), and [getting started guide](https://backstage.io/docs/getting-started/)
- [GitHub repository](https://github.com/backstage/backstage)
- Backstage's [versioning and support policy](https://backstage.io/docs/overview/versioning-policy)
- [Community Discord](https://discord.gg/backstage-687207715902193673) for discussions and support
- [Changelog](https://github.com/backstage/backstage/tree/master/docs/releases/v1.19.0-changelog.md)
- Backstage [Demos](https://backstage.io/demos), [Blog](https://backstage.io/blog), [Roadmap](https://backstage.io/docs/overview/roadmap) and [Plugins](https://backstage.io/plugins)
Sign up for our [newsletter](https://info.backstage.spotify.com/newsletter_subscribe) if you want to be informed about what is happening in the world of Backstage.