mirror of
https://github.com/hashicorp/vault-action.git
synced 2025-11-07 15:16:56 +00:00
docs: add headers docs and toc
This commit is contained in:
parent
4ab6f6070f
commit
198a7ed7d2
2 changed files with 37 additions and 0 deletions
3
.vscode/settings.json
vendored
Normal file
3
.vscode/settings.json
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
{
|
||||||
|
"markdown-toc.depthFrom": 2
|
||||||
|
}
|
||||||
34
README.md
34
README.md
|
|
@ -4,6 +4,24 @@ A helper action for easily pulling secrets from HashiCorp Vault™.
|
||||||
|
|
||||||
By default, this action pulls from [Version 2](https://www.vaultproject.io/docs/secrets/kv/kv-v2/) of the K/V Engine. See examples below for how to [use v1](#using-kv-version-1) as well as [other non-K/V engines](#other-secret-engines).
|
By default, this action pulls from [Version 2](https://www.vaultproject.io/docs/secrets/kv/kv-v2/) of the K/V Engine. See examples below for how to [use v1](#using-kv-version-1) as well as [other non-K/V engines](#other-secret-engines).
|
||||||
|
|
||||||
|
<!-- TOC -->
|
||||||
|
|
||||||
|
- [Example Usage](#example-usage)
|
||||||
|
- [Authentication method](#authentication-method)
|
||||||
|
- [Key Syntax](#key-syntax)
|
||||||
|
- [Simple Key](#simple-key)
|
||||||
|
- [Set Output Variable Name](#set-output-variable-name)
|
||||||
|
- [Multiple Secrets](#multiple-secrets)
|
||||||
|
- [Using K/V version 1](#using-kv-version-1)
|
||||||
|
- [Custom K/V Engine Path](#custom-kv-engine-path)
|
||||||
|
- [Other Secret Engines](#other-secret-engines)
|
||||||
|
- [Adding Extra Headers](#adding-extra-headers)
|
||||||
|
- [Vault Enterprise Features](#vault-enterprise-features)
|
||||||
|
- [Namespace](#namespace)
|
||||||
|
- [Masking](#masking)
|
||||||
|
|
||||||
|
<!-- /TOC -->
|
||||||
|
|
||||||
## Example Usage
|
## Example Usage
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
|
|
@ -202,6 +220,22 @@ would work fine.
|
||||||
|
|
||||||
NOTE: The `Secret Key` is pulled from the `data` property of the response.
|
NOTE: The `Secret Key` is pulled from the `data` property of the response.
|
||||||
|
|
||||||
|
### Adding Extra Headers
|
||||||
|
|
||||||
|
If you ever need to add extra headers to the vault request, say if you need to authenticate with a firewall, all you need to do is set `extraHeaders`:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
with:
|
||||||
|
secrets: |
|
||||||
|
ci/aws accessKey | AWS_ACCESS_KEY_ID ;
|
||||||
|
ci/aws secretKey | AWS_SECRET_ACCESS_KEY
|
||||||
|
extraHeaders: |
|
||||||
|
X-Secure-Id: ${{ secrets.SECURE_ID }}
|
||||||
|
X-Secure-Secret: ${{ secrets.SECURE_SECRET }}
|
||||||
|
```
|
||||||
|
|
||||||
|
This will automatically add the `x-secure-id` and `x-secure-secret` headers to every request to vault.
|
||||||
|
|
||||||
## Vault Enterprise Features
|
## Vault Enterprise Features
|
||||||
|
|
||||||
### Namespace
|
### Namespace
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue