This project has been archived by its maintainers, and is no longer receiving any updates.
Light weight configuration management using Consul
Passport is a command line tool for rendering templates containing information gained from Consul’s Service Discovery API and Key/Value database.
Installation
Passport is available via pypi and can be installed with easy_install or pip:
pip install passport
Usage
usage: passport.py [-h] [--host HOST] [--port PORT] [--datacenter DATACENTER]
{kv,file} path destination
Example
As an example, the following template is stored in the KV database as templates/memcached/memcached.conf
{% set nodes = ['%s:%s' % (r['Address'], r['ServicePort']) for r in consul.catalog.service('memcached')] %}
[memcached]
servers = {{ ','.join(nodes) }}
Invoking passport will render the file with a list of all memcached nodes to /etc/memcached.conf.
passport kv templates/memcached/memcached.conf /etc/memcached.conf
And the output would look something like:
[memcached]
servers = 172.17.0.7:11211,172.17.0.8:11211
Template rendering is done via the Tornado Template engine.
Todo
Add a managed mode where Passport will check for new services on a regular interval and when changes occur, update the rendered template and notify a process using HUP
Add daemonization for managed mode
Add the ability to specify pairs of templates/destinations in a single invocation
Metadata
Release files for passport 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| passport-0.1.1.tar.gz | 4.4 kB | Without provenance | Details for passport-0.1.1.tar.gz |
Release files / passport-0.1.1.tar.gz
| Download URL | passport-0.1.1.tar.gz |
|---|---|
| Size | 4.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5c8e545ffea7cc581cac26b173de53acff602766522656be8deacb601fa2e068
|
|
BLAKE2b-256 checksum How to use checksums |
2a301f1542a65510253e80ef838b347946e9e66ae4e4512fa24dbfc230043644
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for passport 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.