dynamically configure an HTCondor node from a git repository
Project description
Hook to dynamically configure an HTCondor node from a git repository.
Hook Overview
The hook is integrated into a Condor config file to perform the following workflow:
Fetch a git repository to a local cache
Use patterns to select configuration files
Dynamically include configuration in condor
To integrate the hook, use the include command syntax in any HTCondor config file:
include command : condor-git-config https://git.mydomain.com/condor-repos/condor-configs.git
Usage Notes
The hook requires at least Python 3.3 to run.
Installation
Installation provides the condor-git-config executable. All other dependencies are installed automatically.
Stable release version
pip3 install condor_git_config
Current development version
git clone https://github.com/maxfischer2781/condor-git-config.git
./condor-git-config/setup.py install
Argument Files
The condor-git-config executable can use the @ [prefix character](https://docs.python.org/3/library/argparse.html#fromfile-prefix-chars) to read arguments from files. This allows you to prepare options externally
echo $(hostname -d) >> /etc/mycloud/domain
and have them used dynamically to adjust configuration
include command : condor-git-config --branch @/etc/mycloud/domain -- https://git.mydomain.com/condor-repos/condor-configs.git
Configuration Recursion
By default, condor-git-config will not recurse into sub-directories. This allows you to have additional configuration, which is conditionally integrated. For example, consider the following git repository tree:
|- commong.cfg
|- security.cfg
|- aaaron-cloud.cfg
|- aaaron-cloud/
| |- overwrites.cfg
| |- proxy.cfg
|- beebee-cloud.cfg
The aaaron-cloud folder will be ignored by default. You can conditionally include the *-cloud.cfg files like this:
--blacklist '.-cloud\.cfg' --whitelist @/etc/mycloud/flavour
This allows you to further include the files in aaaron-cloud by using include in aaaron-cloud.cfg:
# aaaron-cloud.cfg
include : $(GIT_CONFIG_CACHE_PATH)/overwrites.cfg
include : $(GIT_CONFIG_CACHE_PATH)/proxy.cfg
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
File details
Details for the file condor_git_config-0.0.3.tar.gz
.
File metadata
- Download URL: condor_git_config-0.0.3.tar.gz
- Upload date:
- Size: 4.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
c197da291142fbd4b848a7b64f213b973bf5ace8da25742adf0eb86fcad5927d
|
|
MD5 |
dbc8c53213672409677f5663cc5eae3f
|
|
BLAKE2b-256 |
2f0be2a2928fafb9e01a8f20fe3d1909171e81ea9e6ddc54d5bcb7ded86a9048
|