Skip to content

Add OS type variable to each vmpooler target - #45

Merged
gavindidrichsen merged 3 commits into
mainfrom
add_os_type_to_vmpooler_inventory
Nov 3, 2025
Merged

Add OS type variable to each vmpooler target#45
gavindidrichsen merged 3 commits into
mainfrom
add_os_type_to_vmpooler_inventory

Conversation

@gavindidrichsen

Copy link
Copy Markdown
Owner

Prior to this change, it was impossible to visually inspect the bolt inventory and know what OS each VM was. Now there's a new vars.type added to each target that clearly marks this. For example:

---
targets:
- name: evil-management
  uri: evil-management.delivery.puppetlabs.net
  vars:
    type: win-2022-x86_64
groups:
- name: windows
  config:
    transport: winrm
    winrm:
      user: Administrator
      password:
        _plugin: env_var
        var: VMPOOLER_WINDOWS_PASSWORD
      ssl: false
  facts:
    role: windows
  targets:
  - evil-management
- name: linux
  config:
    transport: ssh
    ssh:
      native-ssh: true
      load-config: true
      login-shell: bash
      tty: false
      host-key-check: false
      run-as: root
      user: root
  facts:
    role: linux
  targets: []

This adds the vmpooler OS type as a variable to the inventory output so I can select a host by OS.

Signed-off-by: Gavin Didrichsen <gavin.didrichsen@gmail.com>
Signed-off-by: Gavin Didrichsen <gavin.didrichsen@gmail.com>
Signed-off-by: Gavin Didrichsen <gavin.didrichsen@gmail.com>
@gavindidrichsen
gavindidrichsen merged commit 76ef685 into main Nov 3, 2025
1 check passed
@gavindidrichsen
gavindidrichsen deleted the add_os_type_to_vmpooler_inventory branch November 3, 2025 16:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant