RexOps / RexOps/Rex

Deduplicate hostlist after hostname expansion

Open
#1,004 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Perl
Stars
737
Forks
214
PR merge metrics
No merged PRs in 30d

Description

Given the server.ini file of:

[group1]
host-[1..2]

[group2]
host-1

[nested]
@group1
@group2

makes host-1 duplicated in the nested group:

$ rex -Tv
Server Groups
 group1  host-[1..2]
 group2  host-1
 nested  host-1, host-[1..2]

leading to multiple execution of a task on the same host.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the shown server.ini and run rex -Tv to inspect the expanded groups. Trace the hostlist and nested-group expansion from that command, then verify that nested contains each hostname once and that a task executes only once per host.

Written by the indexing model from the issue text.

Assessment

Tech stack
perl
Domain
devops
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.