This version is compatible with:
- Puppet Enterprise 2021.0.x, 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x, 2017.3.x, 2017.2.x, 2016.4.x
- Puppet >= 4.10.0 < 8.0.0
Start using this module
This module also contains an example Bolt project with a working
inventory.yaml and several Bolt plans.
- Puppet Bolt 2.15+, installed from an OS package (don't use the RubyGem)
- Note: The example
inventory.yamlassumes Bolt 2.37+ (see comments)
- Note: The example
- A GitLab API personal auth token with sufficient scope
If you are using rvm, you must disable it before running bolt:
rvm use system
Install the RubyGem dependencies using Bolt's
On most platforms:
/opt/puppetlabs/bolt/bin/gem install --user-install -g gem.deps.rb
"C:/Program Files/Puppet Labs/Bolt/bin/gem.bat" install --user-install -g gem.deps.rb
To use this plugin in your own Bolt project, configure it to provide
in the inventory file.
version: 2 groups: - name: repo_targets targets: - _plugin: gitlab_inventory # <- Plugin provides `local` Targets group: # <- GitLab group with Target repos _plugin: env_var var: GITLAB_GROUP default: simp # some optional parameters: gitlab_api_token: # <- API token with scope that can get repos _plugin: env_var # <- (provided by another Bolt plugin) var: GITLAB_API_PRIVATE_TOKEN archived_repos: true allow_list: - '/^pupmod-simp/' - 'simp-core' block_list: - '/_/' config: transport: local local: bundled-ruby: true tmpdir: _plugin: env_var var: PWD
In order to provide an example bolt project in the same module as the inventory
plugin, the example
.. to the
means that (when using the example bolt project) the folder containing this repo
must be named
gitlab_inventory. There may be other weirdness, depending on
this folders' neighbors.
This quirk only affects the example bolt project; it will not affect the inventory plugin or Bolt plans from your own Bolt projects.
Submit PRs at the project's GitHub repository.
resolve_reference: Return a GitLab organization's projects as local inventory targets
gitlab_inventory::count: Example plan, prints number of Targets from inventory
Return a GitLab organization's projects as local inventory targets
Supports noop? false
GitLab group name (or user login) with repos
URL of GitLab instance's base API endpoint
Optional GitLab personal OAuth token, which may be useful to avoid the GitLab API's unauthenticated rate limits
When true, includes archived projects in results.
When set, filters projects by visibility
repo names/patterns to include in inventory, drops all other repos
repo names/patterns to reject from inventory (can reject targets in allow_list)
Bolt Transport type of repository Targets
Additional GEM_PATH path for ruby gems (to find
Example plan, prints number of Targets from inventory
The following parameters are available in the
repo_targets group from inventory
What are tasks?
Modules can contain tasks that take action outside of a desired state managed by Puppet. It’s perfect for troubleshooting or deploying one-off changes, distributing scripts to run across your infrastructure, or automating changes that need to happen in a particular order as part of an application deployment.
Tasks in this module release
What are plans?
Modules can contain plans that take action outside of a desired state managed by Puppet. It’s perfect for troubleshooting or deploying one-off changes, distributing scripts to run across your infrastructure, or automating changes that need to happen in a particular order as part of an application deployment.
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog.
- (Forge-only) Removed broken plan files from tarball published to the Forge
- Initial project
- Inventory plugin that returns GitLab group projects as
- Example Bolt project with working Plans and