feat(yarn-plugin): custom manifest location

added two environment variables that can be used to control the location
of backstage manifest file used by the yarn plugin. this helps using the
plugin in restricted environments without direct or access at all to the
internet.

closes #31101

Signed-off-by: Hellgren Heikki <heikki.hellgren@op.fi>
This commit is contained in:
Hellgren Heikki
2025-09-11 22:24:11 +03:00
parent 89925d16d6
commit d4b682feaf
3 changed files with 513 additions and 33 deletions
+15
View File
@@ -25,6 +25,21 @@ The yarn plugin recognizes the version string `"backstage:^"`, and replaces it
with the appropriate version based on the overall Backstage version in
backstage.json.
### Configuration
The plugin functionality can be configured with environment variables:
- `BACKSTAGE_MANIFEST_BASE_URL` - The base URL for fetching the Backstage version
manifest. Defaults to `https://versions.backstage.io/v1/releases/VERSION/manifest.json`.
Useful for running the plugin in environment without direct access to the internet,
for example by using a mirror of the versions API or a proxy.
Note that the environment variable is just the host name, and the path is appended by
the plugin.
- `BACKSTAGE_MANIFEST_FILE` - Path to a local manifest file. If set, the plugin
will not attempt to fetch the manifest from the network. Useful for running
the plugin in environment without internet access and without mirror of the
versions API.
## Local Development
- Run unit tests: `yarn test`