Set up Backstage in minutes with Roadie
Focus on using Backstage, rather than building and maintaining it.
Installation steps
Install the plugin into your Backstage instance.
yarn --cwd packages/app add @harnessio/backstage-plugin-ci-cd
Generate a Harness API key. Make sure the user creating this API token has necessary permissions, which include project view permission along with pipeline view and execute permissions and same applies for service accounts as well it must have a role assigned that has the roles with adequate permissions as described bef
Add the plugin to the proxy in your app config.
// app-config.yaml
proxy:
# ... existing proxy settings
'/harness/prod':
target: 'https://app.harness.io/'
headers:
'x-api-key': '<YOUR PAT/SAT>'
Add the EntityHarnessCiCdContent
to your EntityPage component.
// In packages/app/src/components/catalog/EntityPage.tsx
import {
isHarnessCiCdAvailable,
EntityHarnessCiCdContent,
} from '@harnessio/backstage-plugin-ci-cd';
const cicdContent = (
// ...
<EntitySwitch.Case if={isHarnessCiCdAvailable}>
<EntityHarnessCiCdContent />
</EntitySwitch.Case>
// ...
);
Update relevant catalog-info.yaml files with Harness annotations. For example add pipelines and services.
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
# ...
annotations:
# optional annotation
harness.io/pipelines: |
labelA: <harness_pipeline_url>
labelB: <harness_pipeline_url>
# here labelA / labelB denotes the value you will see in dropdown in execution list. Refer screentshot 1
# optional annotation
harness.io/services: |
labelA: <harness_service_url>
labelB: <harness_service_url>
Found a mistake? Update these instructions.
Things to know
Useful Info
The Next CI/CD plugin is designed to:
- Connect a Backstage service with a Harness project and view top 50 executions from the pipelines in the project.
- See details about executions - status, execution timestamp and time taken, associated triggers for CI pipelines, services deployed for CD pipelines.
- Specify pipeline IDs (CI) or service IDs (CD) to narrow down on pipeline executions to show in the Backstage service view.
- Retry pipeline executions from the plugin
Useful Links
Set up Backstage in minutes with Roadie
Focus on using Backstage, rather than building and maintaining it.