This is a sample template for Backstage/Red Hat Developer Hub that creates and deploys the Liberty Starter app on Kubernetes. Though this template may work as is, the best practice is for Platform Engineers to design templates specific to their infrastructure. This template should be used as a base for designing your own template in Backstage.
This template (after taking parameters from Backstage/RHDH) does the following:
- Creates a new repo on git containing starter code for application development.
- Creates a new repo on git containing GitOps configuration for deployment.
- Sets up a build pipeline using GitHub Actions.
- Deploys the application code to kubernetes via GitOps.
In order to use this template in Backstage or RHDH the plugins must be properly configured and the underlying development platfrom must be set up. Info on this can be found on the Backstage site as well as the steps we took to set up our platform can be found here. The setup steps vary based on which platform you opt for.
-
Some form of Backstage instance (ex: on-prem Backstage or RHDH)
- Getting Started with Backstage
- Getting Started with RedHat Developer Hub
-
GitHub Application created and connected to your instance. (Backstage) or (RHDH)
-
Kubernetes Frontend and Backend Plugins enabled and configured for the deployment location. (Backstage) or (RHDH)
-
ArgoCD installed and set up. ArgoCD Docs
-
ArgoCD Plugins added to Backstage
-
GitHub Actions plugin installed and set up. (Backstage)
-
Open Liberty Operator installed on your cluster (Docs)
Once all the prerequisites are set up you can use this template with the following steps:
- Click "Create" in your Backstage instance.
- Click "Register Existing Component" on the top right.
- Add the following link into the URL:
https://github.com/OpenLiberty/liberty-backstage-demo/blob/main/liberty-template/template.yaml
and click "Analyze". - Click on "Create" again to view templates.
- Click on "Liberty Getting Started" and follow the instructions.