fix(splunk-on-call-plugin): remove from sample app
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
---
|
||||
'@backstage/plugin-catalog': patch
|
||||
'@backstage/plugin-splunk-on-call': patch
|
||||
---
|
||||
|
||||
|
||||
+1
-11
@@ -12,7 +12,7 @@ backend:
|
||||
connection: ':memory:'
|
||||
cors:
|
||||
origin: http://localhost:3000
|
||||
methods: [GET, POST, PUT, DELETE, PATCH]
|
||||
methods: [GET, POST, PUT, DELETE]
|
||||
credentials: true
|
||||
csp:
|
||||
connect-src: ["'self'", 'http:', 'https:']
|
||||
@@ -30,14 +30,6 @@ proxy:
|
||||
Circle-Token:
|
||||
$env: CIRCLECI_AUTH_TOKEN
|
||||
|
||||
'/splunk-on-call':
|
||||
target: https://api.victorops.com/api-public
|
||||
headers:
|
||||
X-VO-Api-Id:
|
||||
$env: SPLUNK_ON_CALL_API_ID
|
||||
X-VO-Api-Key:
|
||||
$env: SPLUNK_ON_CALL_API_KEY
|
||||
|
||||
'/jenkins/api':
|
||||
target: http://localhost:8080
|
||||
headers:
|
||||
@@ -394,5 +386,3 @@ homepage:
|
||||
timezone: 'Asia/Tokyo'
|
||||
pagerduty:
|
||||
eventsBaseUrl: 'https://events.pagerduty.com/v2'
|
||||
splunkOnCall:
|
||||
username: 'guest'
|
||||
|
||||
@@ -21,6 +21,4 @@ stringData:
|
||||
NEW_RELIC_REST_API_KEY: {{ .Values.auth.newRelicRestApiKey }}
|
||||
TRAVISCI_AUTH_TOKEN: {{ .Values.auth.travisciAuthToken }}
|
||||
PAGERDUTY_TOKEN: {{ .Values.auth.pagerdutyToken }}
|
||||
SPLUNK_ON_CALL_API_ID: {{ .Values.auth.splunkOnCallApiId }}
|
||||
SPLUNK_ON_CALL_API_KEY: {{ .Values.auth.splunkOnCallApiKey }}
|
||||
{{- end }}
|
||||
|
||||
@@ -251,5 +251,3 @@ auth:
|
||||
newRelicRestApiKey: r
|
||||
travisciAuthToken: fake-travis-ci-auth-token
|
||||
pagerdutyToken: h
|
||||
splunkOnCallApiId: h
|
||||
splunkOnCallApiKey: h
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
---
|
||||
title: SplunkOnCall
|
||||
title: Splunk On-Call
|
||||
author: Spotify
|
||||
authorUrl: https://github.com/spotify
|
||||
category: Monitoring
|
||||
description: SplunkOnCall offers a simple way to identify incidents and escalation policies.
|
||||
description: Splunk On-Call offers a simple way to identify incidents and escalation policies.
|
||||
documentation: https://github.com/backstage/backstage/tree/master/plugins/splunk-on-call
|
||||
iconUrl: data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIzMiIgaGVpZ2h0PSIzMiIgdmlld0JveD0iMCAwIDMyIDMyIiBjbGFzcz0idm8tbGVhZi1ibGFjayI+PHBhdGggZD0iTTE1Ljk5OTcgMzJDMjQuODM2MSAzMiAzMiAyNC44MzY4IDMyIDE2LjAwMDJDMzIgNy4xNjM1NiAyNC44MzYxIDAgMTUuOTk5NyAwQzcuMTYzNCAwIDAgNy4xNjM1NiAwIDE2LjAwMDJDMCAyNC44MzY4IDcuMTYzNCAzMiAxNS45OTk3IDMyWk0yMi41Njc1IDE0LjY5MDRMMjMuNjI1OSAxNi41MTU4TDE4Ljg4NTEgMTguOTE0NUwxOC44MSAxOS43MTQxTDIyLjQwMzMgMTguNTc2MUwyMC41OTcyIDIwLjg0MzJMMjAuNDQ2MiAyMS41NjI4TDE4LjI0MzkgMjIuNTUyNUwxOC4wMTc2IDIzLjIzMjJMMTkuMDA0NSAyMi44MTU3TDE2LjM0MjIgMjUuOTEwNFYyOS42MDA0SDE1LjY1NzdWMjUuOTEwNEwxMi45OTU5IDIyLjgxNTdMMTMuOTgyOCAyMy4yMzIyTDEzLjc1NjYgMjIuNTUyNUwxMS41NTQ1IDIxLjU2MjhMMTEuNDAzNiAyMC44NDMyTDkuNTk2OTIgMTguNTc2MUwxMy4xOTA2IDE5LjcxNDFMMTMuMTE0OSAxOC45MTQ1TDguMzc0NDkgMTYuNTE1OEw5LjQzMzM5IDE0LjY5MDRMNy4yMDAyIDExLjUxODlMMTMuMzcxOCAxNC41MDA3TDEzLjQ5NyAxMy42MDM3TDExLjY5MzYgMTAuNjYyTDExLjk1MiAxMC4xNzc0TDExLjExOTUgNi43MTg2N0wxNC4zNTUzIDEwLjEyNjdMMTQuNTQ5MyA4LjI0NDU0TDEzLjU4MTggNS40MjI1M0wxNC44NzMgNS44NTYyNEwxNiAyLjQwMDM5TDE3LjEyNzMgNS44NTYyNEwxOC40MTg2IDUuNDIyNTNMMTcuNDUxMiA4LjI0NDU0TDE3LjY0NTQgMTAuMTI2N0wyMC44ODA3IDYuNzE4NjdMMjAuMDQ4MiAxMC4xNzc0TDIwLjMwNjggMTAuNjYyTDE4LjUwMzQgMTMuNjAzN0wxOC42Mjg4IDE0LjUwMDdMMjQuODAwMiAxMS41MTg5TDIyLjU2NzUgMTQuNjkwNFoiIGZpbGw9JyMyQzJDMkMnLz48L3N2Zz4K
|
||||
npmPackageName: '@backstage/plugin-splunk-on-call'
|
||||
@@ -11,3 +11,4 @@ tags:
|
||||
- monitoring
|
||||
- errors
|
||||
- alerting
|
||||
- splunk
|
||||
|
||||
@@ -92,10 +92,6 @@ import {
|
||||
PullRequestsStatsCard,
|
||||
Router as PullRequestsRouter,
|
||||
} from '@roadiehq/backstage-plugin-github-pull-requests';
|
||||
import {
|
||||
isPluginApplicableToEntity as isSplunkOnCallAvailable,
|
||||
SplunkOnCallCard,
|
||||
} from '@backstage/plugin-splunk-on-call';
|
||||
import {
|
||||
isPluginApplicableToEntity as isTravisCIAvailable,
|
||||
RecentTravisCIBuildsWidget,
|
||||
|
||||
@@ -43,4 +43,3 @@ export { plugin as Buildkite } from '@roadiehq/backstage-plugin-buildkite';
|
||||
export { plugin as Search } from '@backstage/plugin-search';
|
||||
export { plugin as Org } from '@backstage/plugin-org';
|
||||
export { plugin as Kafka } from '@backstage/plugin-kafka';
|
||||
export { plugin as SplunkOnCall } from '@backstage/plugin-splunk-on-call';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
## Overview
|
||||
|
||||
This plugin displays Splunk On-Call information about an entity.
|
||||
This plugin displays Splunk On-Call, formerly VictorOps, information about an entity.
|
||||
|
||||
There is a way to trigger an new incident directly to specific users or/and specific teams.
|
||||
|
||||
@@ -20,7 +20,7 @@ This plugin provides:
|
||||
Install the plugin:
|
||||
|
||||
```bash
|
||||
yarn add @backstage/plugin-splunkoncall
|
||||
yarn add @backstage/plugin-splunk-on-call
|
||||
```
|
||||
|
||||
Add it to the app in `plugins.ts`:
|
||||
@@ -36,7 +36,7 @@ import {
|
||||
isPluginApplicableToEntity as isSplunkOnCallAvailable,
|
||||
SplunkOnCallCard,
|
||||
} from '@backstage/plugin-splunk-on-call';
|
||||
// add to code
|
||||
// ...
|
||||
{
|
||||
isSplunkOnCallAvailable(entity) && (
|
||||
<Grid item md={6}>
|
||||
@@ -60,9 +60,25 @@ splunkOnCall:
|
||||
|
||||
The user supplied must be a valid Splunk On-Call user and a member of your organization.
|
||||
|
||||
In order to be able to make certain API calls you need to add the `PATCH` method to the backend cors methods list.
|
||||
In order to make the API calls, you need to provide a new proxy config which will redirect to the Splunk On-Call API endpoint and add authentication information in the headers:
|
||||
|
||||
```yaml
|
||||
# app-config.yaml
|
||||
proxy:
|
||||
# ...
|
||||
'/splunk-on-call':
|
||||
target: https://api.victorops.com/api-public
|
||||
headers:
|
||||
X-VO-Api-Id:
|
||||
$env: SPLUNK_ON_CALL_API_ID
|
||||
X-VO-Api-Key:
|
||||
$env: SPLUNK_ON_CALL_API_KEY
|
||||
```
|
||||
|
||||
In addition, to make certain API calls (trigger-resolve-acknowledge an incident) you need to add the `PATCH` method to the backend cors methods list.
|
||||
|
||||
```yaml
|
||||
# app-config.yaml
|
||||
backend:
|
||||
# ...
|
||||
cors:
|
||||
@@ -90,3 +106,23 @@ $ SPLUNK_ON_CALL_API_KEY='' SPLUNK_ON_CALL_API_ID='' yarn start
|
||||
```
|
||||
|
||||
This will proxy the request by adding `X-VO-Api-Id` and `X-VO-Api-Key` headers with the provided values.
|
||||
|
||||
You can also add the values in your helm template:
|
||||
|
||||
```yaml
|
||||
# backend-secret.yaml
|
||||
stringData:
|
||||
# ...
|
||||
SPLUNK_ON_CALL_API_ID: { { .Values.auth.splunkOnCallApiId } }
|
||||
SPLUNK_ON_CALL_API_KEY: { { .Values.auth.splunkOnCallApiKey } }
|
||||
```
|
||||
|
||||
To enable it you need to provide them in the chart's values:
|
||||
|
||||
```yaml
|
||||
# values.yaml
|
||||
auth:
|
||||
# ...
|
||||
splunkOnCallApiId: h
|
||||
splunkOnCallApiKey: h
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user