Utilities for exporting backstage plugins as dynamic plugins for installation in Red Hat Developer Hub
Exports plugins as dynamic plugin archives. This should be run after the override-sources
action in order to support per-plugin source overlays, or if patch modifications are needed.
Usage:
- name: Export Dynamic Plugins
uses: ./export-dynamic
with:
plugins-root: plugins
plugins-file: ${{ github.workspace }}/plugins-list.yaml
destination: ${{ github.workspace }}/archives
Key Features:
- Exports plugins as dynamic plugin packages
- Handles both frontend and backend plugins
- Optional container image packaging
Applies patches and source overlays to modify plugin sources before export. This should be run before the export-dynamic
action.
Features:
- Applies patches from
<overlay-root>/patches/
directory usinggit apply
- Copies source overlay files from
<overlay-root>/plugins/{plugin-name}/overlay/
directories - Robust error handling and cleanup
- Ordered patch application (by filename)
- Configurable overlay subfolder name (defaults to "overlay")
Usage:
- name: Override Sources
uses: ./override-sources
with:
overlay-root: ${{ github.workspace }}/my-overlay-repo
workspace-root: .
Inputs:
overlay-root
: Absolute path to the overlay root directory (expectspatches/
andplugins/
subdirectories)workspace-root
: Directory to apply changes to (defaults to ".")source-overlay-folder-name
: Name of subfolder within each plugin directory containing overlay files (defaults to "overlay")
Outputs:
patches-applied
: Number of patches appliedsource-overlay-applied
: Whether source overlay files were copied
jobs:
export-plugins:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Override Sources (apply patches and overlays)
uses: ./override-sources
with:
overlay-root: ${{ github.workspace }}/overlay-repo
workspace-root: .
- name: Export Dynamic Plugins
uses: ./export-dynamic
with:
plugins-root: plugins
plugins-file: ${{ github.workspace }}/plugins-list.yaml
destination: ${{ github.workspace }}/archives