Giter Site home page Giter Site logo

liverpool-victoria / backstage-plugin-jira Goto Github PK

View Code? Open in Web Editor NEW

This project forked from roadiehq/backstage-plugin-jira

0.0 1.0 0.0 1.71 MB

A JIRA plugin for Backstage

License: Apache License 2.0

JavaScript 1.15% TypeScript 98.85%
application-backstage valuestream-platform component-jira

backstage-plugin-jira's Introduction

Jira Plugin for Backstage

a Jira plugin for Backstage

Features

  • Show project details and tasks
  • Activity Stream

How to add Jira project dependency to Backstage app

  1. If you have standalone app (you didn't clone this repo), then do
yarn add @roadiehq/backstage-plugin-jira
  1. Add proxy config:
// app-config.yaml
proxy:
  '/jira/api':
    target: <JIRA_URL>
    headers:
      Authorization:
        $env: JIRA_TOKEN
      Accept: 'application/json'
      Content-Type: 'application/json'
      X-Atlassian-Token: 'no-check'
      User-Agent: "MY-UA-STRING"
  1. Set img-src in Content Security Policy
// app-config.yaml
backend:
  # ...
  csp:
    img-src:
      # "'self'" and 'data' are from the backstage default but must be set since img-src is overriden
      - "'self'"
      - 'data:'
      # Allow your Jira instance for @roadiehq/backstage-plugin-jira
      - 'JIRA_URL'
  1. Add plugin to the list of plugins:
// packages/app/src/plugins.ts
export { jiraPlugin } from '@roadiehq/backstage-plugin-jira';
  1. Add plugin component to your Backstage instance:
// packages/app/src/components/catalog/EntityPage.tsx
import { EntityJiraOverviewCard, isJiraAvailable } from '@roadiehq/backstage-plugin-jira';

const overviewContent = (
  <Grid container spacing={3} alignItems="stretch">
    ...
    <EntitySwitch>
      <EntitySwitch.Case if={isJiraAvailable}>
        <Grid item md={6}>
          <EntityJiraOverviewCard />
        </Grid>
      </EntitySwitch.Case>
    </EntitySwitch>
  </Grid>
);

How to use Jira plugin in Backstage

  1. Add annotation to the yaml config file of a component:
metadata:
  annotations:
    jira/project-key: <example-jira-project-key>
    jira/component: <example-component> # optional, you might skip value to fetch data for all components
  1. Get and provide JIRA_TOKEN as env variable:
    1. Obtain you personal token from jira: https://id.atlassian.com/manage-profile/security/api-tokens
    2. Create a base64-encoded string by converting ":", for example [email protected]:hTBgqVcrcxRYpT5TCzTA9C0F converts to amlyYS1tYWlsQGV4YW1wbGUuY29tOmhUQmdxVmNyY3hSWXBUNVRDelRBOUMwRg==
    3. Save the environmental variable JIRA_TOKEN with Basic prefix, eg: JIRA_TOKEN='Basic amlyYS1tYWlsQGV4YW1wbGUuY29tOmhUQmdxVmNyY3hSWXBUNVRDelRBOUMwRg=='

Links

backstage-plugin-jira's People

Contributors

lewtakm avatar mcalus3 avatar dtuite avatar snyk-bot avatar padraigobrien avatar adamdmharvey avatar xantier avatar athal7 avatar ayshiff avatar irma12 avatar martina-if avatar o5ten avatar kuangp avatar bobalong79 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.