Tools for Puppet Development
- Python 3
(For reference only, they will be installed during setup into a virtual environment).
- Pip
- colored
- dashtable (which depends on bs4)
- pyyaml
export PUP_DEV_BASE=/usr/local/src/puppet-dev
git clone https://github.com/ncsa/puppet-dev.git $PUP_DEV_BASE
$PUP_DEV_BASE/setup.sh
vim $PUP_DEV_BASE/bin/branches.sh
- Check / Set values for:
- REPO_NAMES
- REFERENCE_NAMES
- TOPIC_KEYWORD
- Check / Set values for:
All commands:
- are installed to
/usr/local/bin
- assume per-user puppet repo working directories exist at
$HOME/puppet/<repo_name>
Report merge status of topic branches against mainline branches.
R10K creates dynamic environments from multiple repos, where control
is
a puppet control repo, hiera
contains private, secret data, and legacy
has
local, private, unpublished modules.
branches
Show current branch for each repo (control
, hiera
, legacy
).
repo_status
Create the puppet environment /etc/puppetlabs/code/environments/wip_<USERNAME>
using contents of current working directories for each repo (control
, hiera
, legacy
)
for testing live changes without commit-push-deploy cycle.
Note: <USERNAME>
must be passed as a parameter on the cmdline
- root@puppet-master#
update_wip_env <USERNAME>
Checkout the specified branch in each repo (control
, hiera
, legacy
)
For each repo without a matching branch, checkout "production" instead.
/usr/local/bin/repo_checkout <TOPIC_BRANCH>