8.1.3 HashiCorp Vault Support

Micronaut features support for integration with HashiCorp Vault as a distributed configuration source.

To enable support for Vault Configuration simply add the following configuration to your bootstrap.yml file:

Integrating with HashiCorp Vault

  1. micronaut:
  2. application:
  3. name: hello-world
  4. config-client:
  5. enabled: true
  6. vault:
  7. client:
  8. config:
  9. enabled: true

See the configuration reference for all configuration options.

Micronaut will use the configured micronaut.application.name to lookup property sources for the application from Vault.

Table 1. Configuration Resolution Precedence
FolderDescription

/application

Configuration shared by all applications

/[APPLICATION_NAME]

Application specific configuration

/application/[ENV_NAME]

Configuration shared by all applications for an active environment name

/[APPLICATION_NAME]/[ENV_NAME]

Application specific configuration for an active environment name

See the Documentation for HashiCorp Vault for more information on how to setup the server.