Streamline configuration management by fetching and updating configurations from a Spring Cloud Config Server in Python.
Project description
#config-server-client-python
Streamline configuration management by fetching and updating configurations from a sping-cloud-config-server in Python.
#How to use config-serve-client-python package in django/flask framework.
Within the repository, we maintain clients for Python Framework. The Python client is responsible for retrieving configurations from the Spring Cloud Config Server and seamlessly integrating them as environment variables within the container.
#Python sping-cloud-config-server client
1} Add config-server-client-python package to requirements.txt
config-server-client-python==<version_no>
2} In manage.py import ConfigServerPythonClient as given below.
from src.config_server_python_library import ConfigServerPythonClient
3} Initiate ConfigServerPythonClient function in main.
client = ConfigServerPythonClient(os.getenv('CONFIG_SERVER_URL'), <service-name>, <profile-list>, os.getenv('COMMIT_ID'), os.getenv('ENV_NAMESPACE'))
client.write_configs_to_env()
#How to push a new version of config-server-client-python to nexus:
1} Clone config-server-client-python repo.
git clone https://github.com/jayantreddy181198/config-server-client-python.git <destination_path>/config-server-client-python
2} Install twine and setuptools from pypi if not exists already.
pip install twine setuptools
3} Navigate to config-server-client-python repo.
cd <destination_path>/config-server-client-python
4} Make the required changes and update the version in setup.py
5} RUN below command to create sdist.
python setup.py sdist bdist_wheel
6} Upload package to nexus.
twine upload --repository pypi-release dist/*
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file config_server_client_python-1.0.1.tar.gz
.
File metadata
- Download URL: config_server_client_python-1.0.1.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 44fad411fb8a438c6ebb7b1896f8aa144d61a5f9c9a41c2222def6b76b9133a8 |
|
MD5 | a9b1600163148675daca5146253ffe9e |
|
BLAKE2b-256 | 7fbce39d96dd785da6dd0dd15b248e0aee3f711165f54857e948f6af0e6d1d85 |
File details
Details for the file config_server_client_python-1.0.1-py3-none-any.whl
.
File metadata
- Download URL: config_server_client_python-1.0.1-py3-none-any.whl
- Upload date:
- Size: 5.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9df6ceb3bda76a367c08f18ee44e731f401deab1ca318245b32807aadbf4d559 |
|
MD5 | dc4945d68136b02f7c8706e8c1df41d0 |
|
BLAKE2b-256 | 1ee84144e908cc81ec83c4020b19ee76d9381798f2d4583873b342c2af43c91c |