diff --git a/Jenkinsfile b/Jenkinsfile index 9cabcc0..b92ec00 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -52,9 +52,9 @@ pipeline { // Build the limit flag def limitValue = '' if (isDockerPlaybook) { - // Docker playbooks always target 'docker' tagged hosts - // If user provides a limit, use intersection (docker AND limit) - limitValue = params.LIMIT ? "docker:&${params.LIMIT}" : 'docker' + // Docker playbooks always target 'docker_hosts' group + // If user provides a limit, use intersection (docker_hosts AND limit) + limitValue = params.LIMIT ? "docker_hosts:&${params.LIMIT}" : 'docker_hosts' } else { limitValue = params.LIMIT ?: '' } @@ -67,7 +67,7 @@ pipeline { echo "Check flag: '${checkFlag}'" echo "Limit: '${limitValue}'" if (isDockerPlaybook) { - echo "Docker playbook detected - targeting hosts with 'docker' tag" + echo "Docker playbook detected - targeting 'docker_hosts' group" } sh """ diff --git a/README.md b/README.md index f21882d..cff35c6 100644 --- a/README.md +++ b/README.md @@ -35,19 +35,19 @@ The Jenkins pipeline provides a parameterized build with: | `LIMIT` | Optionally limit to specific hosts (e.g., `plex`, `media-app`) | | `DRY_RUN` | Run in check mode without making changes | -The pipeline automatically targets hosts with the `docker` tag. When a limit is provided, it uses an intersection pattern (`docker:&`) to ensure only docker-tagged hosts matching the limit are affected. +The pipeline automatically targets hosts in the `docker_hosts` group. When a limit is provided, it uses an intersection pattern (`docker_hosts:&`) to ensure only docker hosts matching the limit are affected. ### Via Command Line ```bash # Update all docker hosts -ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerUpdate.yml --limit docker +ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerUpdate.yml --limit docker_hosts # Update a specific host -ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerUpdate.yml --limit docker:&plex +ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerUpdate.yml --limit 'docker_hosts:&plex' # Prune all docker hosts (dry run) -ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerPrune.yaml --limit docker --check --diff +ansible-playbook -i inventories/inventory.proxmox.yml playbooks/dockerPrune.yaml --limit docker_hosts --check --diff ``` ## Inventory