database

package
v0.10.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 23, 2024 License: Apache-2.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DynamicSecretDataSource

func DynamicSecretDataSource(_ string, source string) (dynamicSecretDataSource string, err error)

DynamicSecretDataSource creates a SQL data source but instead of passing username:password in the connection source, one just has to pass in a Vault role name:

ds, err := DynamicSecretDataSource("mysql", "my-role@localhost:3306/dbname?parseTime=True")

MySQL (github.com/go-sql-driver/mysql) and PostgreSQL URI is supported.

The underlying Vault client will make sure that the credential is renewed when it is close to the time of expiry.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL