Helper classes to integrate psycopg2 with Vault
Project description
vault-psycopg2
Helper classes to integrate psycopg2 with Vault
Usage:
pip install vault-psycopg2
from vault_psycopg2 import VaultPsycopg
vp = VaultPsycopg(
database_config={
'host': 'localhost',
'dbname': 'name_of_database'
},
vault_config={
'server': 'http://127.0.0.1:8200',
'connection_mode': 'ec2',
'nonce': '5daa3d21-4e21-4bd5-8978-fcb81e658d8b',
'role': 'some-instance'
}
)
# An instance of psycopg2.Connection that is properly authenticated
vp.connection
Other examples of vault config:
vault_config={
'server': 'http://127.0.0.1:8200',
'connection_mode': 'token',
'token': '5daa3d21-4e21-4bd5-8978-fcb81e658d8b'
}
vault_config={
'server': 'http://127.0.0.1:8200',
'connection_mode': 'userpass',
'username': 'john.doe',
'password': 'xyzzyabc'
}
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
vault-psycopg2-0.1.11.tar.gz
(2.7 kB
view details)
Built Distribution
File details
Details for the file vault-psycopg2-0.1.11.tar.gz
.
File metadata
- Download URL: vault-psycopg2-0.1.11.tar.gz
- Upload date:
- Size: 2.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 65effe27f939fafa320bbbdd0a51291d3aa80394905bec8b35d4d8be810fae65 |
|
MD5 | 2a14b4ad707a662422e4a8abf8614ec3 |
|
BLAKE2b-256 | ce80c887532e2eb23a5657f5331a20f52dea78796234f19f8369fa48b4746cb7 |
File details
Details for the file vault_psycopg2-0.1.11-py3-none-any.whl
.
File metadata
- Download URL: vault_psycopg2-0.1.11-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fcafe0666b26f3ef687207ee1b1fd98c13b62f31110ef9192c1e308dab10c99f |
|
MD5 | 1d90aae9710eff80b1b33ffaf4cf351e |
|
BLAKE2b-256 | d71f13ae9a1321f8b15c37784bb09cc922c93033d2cb7b42c86ea6de60757641 |