Skip to content

Commit

Permalink
Merge pull request #1 from sysdiglabs/dev-backlink
Browse files Browse the repository at this point in the history
Add backlinking
  • Loading branch information
Jujuyeh authored Mar 1, 2024
2 parents a4ef86f + 3c8b33d commit 187cf5a
Show file tree
Hide file tree
Showing 11 changed files with 379 additions and 319 deletions.
Binary file removed .DS_Store
Binary file not shown.
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ yarn --cwd packages/app add @sysdig/backstage-plugin-sysdig

```bash
# From your Backstage root directory
git clone https://github.com/sysdiglabs/backstage-plugin-sysdig -o plugins/sysdig
git clone https://github.com/sysdiglabs/backstage-plugin-sysdig plugins/sysdig
yarn install
```

Expand Down Expand Up @@ -72,19 +72,23 @@ Edit `app-config.yaml` and add to the API endpoints the following details:
proxy:
endpoints:
+ '/sysdig':
+ target: 'https://secure.sysdig.com/'
+ target: ${SYSDIG_SECURE_ENDPOINT}
+ changeOrigin: true
+ allowedMethods: ['GET']
+ headers:
+ "Authorization": "Bearer ${SYSDIG_SECURE_TOKEN}"
+ "Content-Type": "application/json"
+ "Accept": "application/json"
+ "X-Sysdig-Product": "SDS"
```

Replace the value for `target` with your Sysdig Secure Endpoint.
...

+ sysdig:
+ endpoint: ${SYSDIG_SECURE_ENDPOINT}
```

You can replace `${SYSDIG_SECURE_TOKEN}` with your Sysdig Secure API Token, or you can set it to the `SYSDIG_SECURE_TOKEN` environment variable when deploying your Backstage instance.
- Set the environment variable `SYSDIG_SECURE_ENDPOINT` to your Sysdig Secure Endpoint.
- Likewise, set `SYSDIG_SECURE_TOKEN` to your Sysdig Secure API Token.


## How to annotate services
Expand Down
25 changes: 25 additions & 0 deletions config.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/*
* Copyright 2021 The Backstage Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export interface Config {
/** Configurations for the Sysdig plugin */
sysdig: {
/**
* Endpoint of Sysdig Secure.
* @visibility frontend
*/
endpoint: string;
};
}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@
"msw": "^1.0.0"
},
"files": [
"config.d.ts",
"dist"
]
],
"configSchema": "config.d.ts"
}
Loading

0 comments on commit 187cf5a

Please sign in to comment.