https://github.com/douglasfarinelli/python-awsenviron
Load environment variables from AWS Parameter Store
https://github.com/douglasfarinelli/python-awsenviron
aws env environment-variables parameter-store python
Last synced: 3 months ago
JSON representation
Load environment variables from AWS Parameter Store
- Host: GitHub
- URL: https://github.com/douglasfarinelli/python-awsenviron
- Owner: douglasfarinelli
- License: mit
- Created: 2018-02-13T23:22:13.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T06:50:30.000Z (over 3 years ago)
- Last Synced: 2026-01-02T13:57:30.418Z (4 months ago)
- Topics: aws, env, environment-variables, parameter-store, python
- Language: Python
- Homepage: https://douglasfarinelli.github.io/python-awsenviron/
- Size: 56.6 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
python-awsenviron
================
[](https://pypi.python.org/pypi/awsenviron)
[](https://travis-ci.org/douglasfarinelli/python-awsenviron)
[](https://coveralls.io/github/douglasfarinelli/python-awsenviron?branch=master)
[](https://pypi.python.org/pypi/awsenviron)
The `awsenviron` reads the key, value pair from [AWS Parameter Store](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-paramstore.html) and adds them to environment variable. This was inspired by [python-dotenv](https://github.com/theskumar/python-dotenv) and [12-factor](https://12factor.net/config) principles.
Installation
============
```bash
pip install awsenviron
```
or
```bash
pipenv install awsenviron
```
Usage
=====
```python
awsenviron.load_from_parameter_store(path='')
```
Now, you can access the variables either from system environment variable:
```python
import os
DATABASE_URI = os.environ.get('DATABASE_URI')
```
Authentication
==============
awsenviron use `boto3` to authentication, [click here](http://boto3.readthedocs.io/en/latest/guide/configuration.html) to see the methods.