See builds in Backstage
In the `backstage/packages/app` project add the plugin as a `package.json` dependency:
yarn add @roadiehq/backstage-plugin-travis-ci
Add proxy configuration'
// app-config.yaml
proxy:
...
'/travisci/api':
target: https://api.travis-ci.com
changeOrigin: true
headers:
Authorization:
$secret:
env: TRAVISCI_AUTH_TOKEN
travis-api-version: 3
Add plugin to the list of plugins:
// packages/app/src/plugins.ts
export { plugin as TravisCI } from '@roadiehq/backstage-plugin-travis-ci';
Add plugin to the `entitytPage.tsx` source file:
// packages/app/src/components/catalog/EntityPage.tsx
case isTravisCIAvailable(entity):
content = <RecentTravisCIBuildsWidget entity={entity} />;
break;
add annotation to the yaml config file of a component
travis-ci.com/repo-slug: owner-name/project-name
add your developer api key (from https://travis-ci.com/account/preferences) to the environmental variables for your backstage backend server
TRAVISCI_AUTH_TOKEN="token your-api-key"
To use the Travis CI Backstage plugin, first visit Travis CI to get an API token: https://travis-ci.com/account/preferences
There are two versions of Travis CI: https://travis-ci.com and https://travis-ci.org. travis-ci.org is deprecated and not supported in this plugin.
Copy the token to your clipboard.
Each build can be retried via the column on the right hand side.
To get the latest news, deep dives into Backstage features, and a roundup of recent open-source action, sign up for Roadie's Backstage Weekly. See recent editions.