Sync hostlist and builds config files for services.
Project description
Hostlist reads yaml lists with information about hosts and generates config files and inventory for several services.
Quickstart
Example input files are in the tests directory. Hostlists are defined in the hostslists subdirectory, where the filename encodes the hosttype and institute attributes of the contained hosts.
Run buildfiles to generate the output. buildfiles –help shows the available options.
Configuration
The main configuration is in config.yml in the working directory. Hostlists are collected in a directory listed in config.yml.
Services
At the moment the supported services are:
/etc/hosts, can also be used for dnsmasq
dhcpd
ansible inventory
munin
ssh_known_hosts generation
Web daemon
You can start hostlist-daemon to serve the generated content via http. Start hostlist-daemon where you would run buildfiles and
DNSVS Synchronization
Besides generating config files, the hostlist can also be synchronized against DNSVS, which is the dns management system used by https://www.scc.kit.edu.
Tests
To run the unit tests:
nosetest tests
Contribute
Feel free to use the code and adjust it to your needs. Pull requests are welcome!
Style guide
The code should obey PEP8 (as enforced by flake8 or pylint) when possible.
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 Distributions
Built Distribution
Hashes for hostlist-1.1.0a2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6ab2626bf3a2124d2dfc5f41df5b6af5cae8f86f553063f7da2d86e0b96fa400 |
|
MD5 | ee617b6df647df01093224eeb052d12a |
|
BLAKE2b-256 | a8d609fcdb956faa30a5e9834abc392859ad033ad4f08f40658c3135f2333d50 |