open-index/open-npm huggingface dataset:
npm package: @ovotech/backstage-plugin-confluence
Description: This plugin integrates Confluence documents to Backstage' search engine.
Latest version: 0.0.15

# Confluence search plugin [![](https://img.shields.io/npm/v/@k-phoen/backstage-plugin-confluence.svg)](https://www.npmjs.com/package/@k-phoen/backstage-plugin-confluence)

This plugin integrates Confluence documents to Backstage' search engine.

**Note:** it is used in combination with its [backend counter-part](../search-confluence-backend/).

## How does it look?

Search results:

![Search results](./docs/confluence_search_result.png)

## Installation

Add the plugin to your frontend app:

```bash
cd packages/app && yarn add @k-phoen/backstage-plugin-confluence
```

Nicely display Confluence search results:

```typescript
// packages/app/src/components/search/SearchPage.tsx

import { DocsIcon } from '@backstage/core-components';
import { ConfluenceResultListItem } from '@k-phoen/backstage-plugin-confluence';

// ...
<SearchType.Accordion
  name="Result Type"
  types={[
    // ...
    {
      value: 'confluence',
      name: 'Confluence',
      icon: <DocsIcon />,
    },
  ]}
/>

<SearchResult>
  // ...
  <ConfluenceResultListItem />
</SearchResult>
```

## License

This library is under the [MIT](../../LICENSE) license.
npm package: @ovotech/berglas-node
Description: Node library for decrypting Berglas secrets
Author: Christian Benincasa
Latest version: 1.1.4

# Overview

Node library to interact with [Berglas](https://github.com/GoogleCloudPlatform/berglas)-managed secrets in Google Cloud Platform.

# Usage

## Installation

```
yarn add @ovotech/berglas-node
```

# Use Case

Currently, Berglas only supports the Go runtime on Cloud Functions. With this library, one is able to use Berglas secrets while running NodeJS functions on Cloud Functions.

## Interact

The library has two main functions: `resolve` and `substitute`.

`resolve` retrieves and deciphers a single Berglas secret.
`substitute` replaces environment variables values beginning with the Berglas prefix (`berglas://`) in the process with their resolved values.

## Examples

### Resolving a single secret

```js
// index.js

import { resolve } from "@ovotech/berglas-node";

let mySecret;

async function funcThatNeedsSecret() {
  if (!mySecret) {
    mySecret = await resolve(PROJECT_ID, "secrets-bucket/mySecret");
  }

  // Use deciphered secret value;
}

funcThatNeedsSecret();
```

### Substituting all environment vars at the start of an application

```js
// index.js

// Before:
// process.env.FOO=berglas://secrets-bucket/foo

import { substitute } from "@ovotech/berglas-node";

async function main() {
  await substitute();

  // Run application, pulling secrets from environvment vars
  // After: process.env.FOO=bar
}

main();
```

# Future

This is a very simplistic library to get basic Berglas functionality working in environvments like NodeJS on Cloud Functions. However, there is always room for improvement. Some ideas so far:

- Synchronous versions of functions. The benefit here is that then `substitute` could run immediately upon import and make integration with applications more seamless (and we don't have to wait for top-level await!)
- Listing, creating secrets

If you have any ideas or feature requests, please open an issue!

# License

This library is licensed under the MIT license. Do what you want!