68db610ce5
*Total -- 1,143.96kb -> 883.47kb (22.77%) /microsite/blog/assets/2020-12-22/versions-bump.png -- 143.92kb -> 82.45kb (42.71%) /plugins/fossa/docs/fossa-card.png -- 60.17kb -> 40.17kb (33.24%) /plugins/sentry/docs/sentry-card.png -- 142.60kb -> 96.30kb (32.47%) /plugins/lighthouse/images/audit-view.png -- 143.60kb -> 99.46kb (30.74%) /plugins/lighthouse/images/lighthouse-page.png -- 130.63kb -> 91.65kb (29.84%) /docs/assets/software-catalog/bsc-register-2.png -- 128.51kb -> 100.98kb (21.42%) /microsite/blog/assets/2020-12-22/stability-index-hero.gif -- 391.12kb -> 369.08kb (5.63%) /plugins/pagerduty/src/assets/emptystate.svg -- 3.41kb -> 3.37kb (1.06%) Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
FOSSA Plugin
The FOSSA Plugin displays code statistics from FOSSA.
Getting Started
- Install the FOSSA Plugin:
# packages/app
yarn add @backstage/plugin-fossa
- Add plugin to the app:
// packages/app/src/plugins.ts
export { plugin as Fossa } from '@backstage/plugin-fossa';
- Add the
FossaCardto the EntityPage:
// packages/app/src/components/catalog/EntityPage.tsx
import { FossaCard } from '@backstage/plugin-fossa';
const OverviewContent = ({ entity }: { entity: Entity }) => (
<Grid container spacing={3} alignItems="stretch">
// ...
<Grid item xs={12} sm={6} md={4}>
<FossaCard entity={entity} />
</Grid>
// ...
</Grid>
);
- Add the proxy config:
# app-config.yaml
proxy:
'/fossa':
target: https://app.fossa.io/api
allowedMethods: ['GET']
headers:
Authorization:
# Content: 'token <your-fossa-api-token>'
$env: FOSSA_AUTH_HEADER
# if you have a fossa organization, configure your id here
fossa:
organizationId: <your-fossa-organization-id>
-
Get an api-token and provide
FOSSA_AUTH_HEADERas env variable (https://app.fossa.com/account/settings/integrations/api_tokens) -
Add the
fossa.io/project-nameannotation to your catalog-info.yaml file:
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
name: backstage
description: |
Backstage is an open-source developer portal that puts the developer experience first.
annotations:
fossa.io/project-name: YOUR_PROJECT_NAME
spec:
type: library
owner: CNCF
lifecycle: experimental
