get-hc-secrets 1.5.22__tar.gz → 1.5.23__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/PKG-INFO +1 -1
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/pyproject.toml +1 -1
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/getSecrets/__init__.py +3 -3
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/PKG-INFO +1 -1
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/LICENSE +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/README.md +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/setup.cfg +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/SOURCES.txt +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/dependency_links.txt +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/requires.txt +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/top_level.txt +0 -0
- {get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/tests/test_getsecrets.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: get_hc_secrets
|
|
3
|
-
Version: 1.5.
|
|
3
|
+
Version: 1.5.23
|
|
4
4
|
Summary: A package to read secrets from Hashicorp vault or from a local file
|
|
5
5
|
Author-email: Xavier Mayeur <xavier@mayeur.be>
|
|
6
6
|
Project-URL: Homepage, https://github.com/xmayeur/getSecrets
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
import os
|
|
3
|
-
import re
|
|
4
3
|
import socket
|
|
5
4
|
import sys
|
|
6
5
|
from os import getenv
|
|
7
6
|
from os.path import join
|
|
8
|
-
|
|
7
|
+
import urllib.parse
|
|
9
8
|
import requests
|
|
10
9
|
import urllib3
|
|
11
10
|
import yaml
|
|
@@ -52,7 +51,8 @@ def get_secret(id: str, repo: str = 'secret') -> dict:
|
|
|
52
51
|
certs = '/etc/vault/bundle.pem'
|
|
53
52
|
else:
|
|
54
53
|
certs = join(_home, _config['vault']['certs'].replace("~/", ''))
|
|
55
|
-
|
|
54
|
+
parsed_url = urllib.parse.urlparse(base_url)
|
|
55
|
+
hostname = parsed_url.netloc.split(':')[0]
|
|
56
56
|
ip = socket.gethostbyname(hostname)
|
|
57
57
|
if '192.168.' not in ip:
|
|
58
58
|
certs = where()
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: get_hc_secrets
|
|
3
|
-
Version: 1.5.
|
|
3
|
+
Version: 1.5.23
|
|
4
4
|
Summary: A package to read secrets from Hashicorp vault or from a local file
|
|
5
5
|
Author-email: Xavier Mayeur <xavier@mayeur.be>
|
|
6
6
|
Project-URL: Homepage, https://github.com/xmayeur/getSecrets
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{get_hc_secrets-1.5.22 → get_hc_secrets-1.5.23}/src/get_hc_secrets.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|