2.1.23 • Published 21 hours ago

@roadiehq/backstage-plugin-travis-ci v2.1.23

Weekly downloads
1,976
License
Apache-2.0
Repository
github
Last release
21 hours ago

Travis CI Plugin for Backstage

a list of builds in the Travis CI plugin for Backstage

Features

  • List Travis CI Builds
  • Retrigger builds

How to add Travis-ci project dependency to Backstage app

If you have your own backstage application without this plugin, here are instructions how to add it:

  1. In the backstage/packages/app project add the plugin as a package.json dependency:
yarn add @roadiehq/backstage-plugin-travis-ci
  1. add configuration in app-config.yaml file in the root directory:

In the proxy object:

proxy:

  ...

  '/travisci/api':
    target: https://api.travis-ci.com
    changeOrigin: true
    headers:
      Authorization: ${TRAVISCI_AUTH_TOKEN}
      travis-api-version: 3

and as a separate configuration object:

travisci:
  baseUrl: 'https://travis-ci.com/'
  1. Import it into your Backstage application:
// packages/app/src/components/catalog/EntityPage.tsx
import {
  EntityTravisCIContent,
  EntityTravisCIOverviewCard,
  isTravisciAvailable,
} from '@roadiehq/backstage-plugin-travis-ci';
  1. Add plugin to the EntityPage.tsx source file:
// packages/app/src/components/catalog/EntityPage.tsx
export const cicdContent = (
  <EntitySwitch>
    <EntitySwitch.Case if={isTravisciAvailable}>
      <EntityTravisCIContent />
    </EntitySwitch.Case>
    ...
  </EntitySwitch>
);
  1. Add a recent Travis-CI builds widget/card to the overview tab to the entityPage.tsx source file:
export const cicdCard = (
  <EntitySwitch>
    <EntitySwitch.Case if={isTravisciAvailable}>
      <Grid item sm={6}>
        <EntityTravisCIOverviewCard />
      </Grid>
    </EntitySwitch.Case>
  </EntitySwitch>
);

How to use Travis-ci plugin in Backstage

Travis-ci plugin is a part of the Backstage sample app. To start using it for your component, you have to:

  1. Add an annotation to the yaml config file of a component:
travis-ci.com/repo-slug: <owner-name>/<project-name>
  1. Add your developer api key to the environment variables of your backstage backend server (you can find it in https://travis-ci.com/account/preferences), in the form of the word 'token' followed by your api key. So it should look like this:

    TRAVISCI_AUTH_TOKEN="token <your-api-key>"

Developing the plugin locally

The easiest way is to clone the plugin repo into the plugins/ directory of your backstage code base:

git clone https://github.com/RoadieHQ/backstage-plugin-travis-ci.git travis-ci

and run yarn install in the root backstage directory - it will create a symbolic link, so the dependency will be provided from the source code instead of node_modules package.

Links

2.1.23

21 hours ago

2.1.22

1 month ago

2.1.21

2 months ago

2.1.20

2 months ago

2.1.16

6 months ago

2.1.17

5 months ago

2.1.14

9 months ago

2.1.15

7 months ago

2.1.13

10 months ago

2.1.12

11 months ago

2.1.10

11 months ago

2.1.11

11 months ago

2.1.9

1 year ago

2.1.8

1 year ago

2.1.7

1 year ago

2.1.4

1 year ago

2.1.6

1 year ago

2.1.5

1 year ago

2.1.2

1 year ago

2.1.1

1 year ago

2.1.3

1 year ago

2.0.6

2 years ago

2.1.0

2 years ago

2.0.5

2 years ago

2.0.3

2 years ago

2.0.2

2 years ago

2.0.4

2 years ago

2.0.1

2 years ago

1.4.0

2 years ago

1.3.11

2 years ago

2.0.0

2 years ago

1.3.10

2 years ago

1.3.9

2 years ago

1.3.8

2 years ago

1.3.6

2 years ago

1.3.5

2 years ago

1.3.4

2 years ago

1.3.3

2 years ago

1.3.2

2 years ago

1.3.1

2 years ago

1.2.0

2 years ago

1.2.3

2 years ago

1.2.2

2 years ago

1.2.1

2 years ago

1.1.2

3 years ago

1.1.1

3 years ago

1.1.0

3 years ago

1.0.14

3 years ago

1.0.13

3 years ago

1.0.12

3 years ago

1.0.11

3 years ago

1.0.9

3 years ago

1.0.10

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago

0.4.7

3 years ago

0.4.6

3 years ago

0.4.5

3 years ago

0.4.4

3 years ago

0.4.3

3 years ago

0.3.0

3 years ago

0.2.8

3 years ago

0.2.7

4 years ago

0.2.6

4 years ago

0.2.5

4 years ago

0.2.4

4 years ago

0.2.3

4 years ago

0.2.2

4 years ago

0.2.1

4 years ago

0.2.0

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago