hcp vault-secrets secrets create
Command: hcp vault-secrets secrets create
The hcp vault-secrets secrets create
command creates a new static, rotating,
or dynamic secret under a Vault Secrets application. The configuration for
creating your rotating or dynamic secret will be read from the provided HCL
config file. The following fields are required in the config file: [type
integration_name details]. For help populating the details for a dynamic or
rotating secret, please refer to the API reference
documentation.
Usage
Examples
Create a new static secret in the Vault Secrets application on your active profile:
Create a new secret in a Vault Secrets application by piping the plaintext secret from a command output:
Create a new rotating secret on your active profile from a config file:
Create a new dynamic secret interactively on your active profile:
Positional arguments
NAME
- The name of the secret to create.
Flags
--data-file=DATA_FILE_PATH
- File path to read secret data from. Set this to '-' to read the secret data from stdin for a static secret.--secret-type=SECRET_TYPE
- The type of secret to create: static, rotating, or dynamic.
Inherited Flags
--app=NAME
- The name of the Vault Secrets application. If not specified, the value from the active profile will be used.