ansible nodes source does not process groups correctly

61 views
Skip to first unread message

Jim Richard

unread,
Nov 5, 2024, 10:47:45 AMNov 5
to rundeck-discuss
this is a show stopper, makes the plugin un-usable for most people.

this only happens with "gather facts" is off.... 

which is a great feature by the way, the ability to tell Rundeck to not run a full playbook to generate nodes and instead just run ansible-inventory, so thank you, thank you for that but...

it has to be able to process groups correctly.

yes, I have "duplicate_dict_key = ignore" in my ansible.cfg

at the end here is a simple inventory file that will demo the problem very clearly

try it yourself please with the latest version of Rundeck and the "out of the box" Ansible plugin version that ships with it.

maybe this one fixes it ??

and I think it's the same issue described here:

I'd be happy to try building from the pull 400 branch, I just don't know how to do a Gradle build on Linux/Rocky 8. I am very familiar with lots of other build tools though, maven, sbt, npm etc so maybe if I give it a try I might be able to figure it out

but maybe for the lazy among us :) - can you give me a quick "this is how you build the plugin on Linux" instructions please.

clearly it will start with "git clone, switch to the right branch and then...." some commands .... 



########################################

all:

  children:

    all_hosts:

      hosts:

        host-1: {}

        host-2: {}

        host-3: {}

    group_1:

      hosts:

        host-3: {}

        host-2: {}

    group_2:

      hosts:

        host-1: {}

        host-2: {}

    group_3:

      hosts:

        host-3: {}

    group_4:

      hosts:

        host-2: {}

    ungrouped: {}









Jim Richard

unread,
Nov 5, 2024, 11:44:51 AMNov 5
to rundeck-discuss
the answer is:

sh ./gradlew build 

rac...@rundeck.com

unread,
Nov 5, 2024, 11:48:22 AMNov 5
to rundeck-discuss

Hi Ricard,

It focused on subgroups specifically. However, that PR is still in development.

I’d be happy to try building from the pull 400 branch, I just don’t know how to do a Gradle build on Linux/Rocky 8. I am very familiar with lots of other build tools though, maven, sbt, npm etc so maybe if I give it a try I might be able to figure it out

but maybe for the lazy among us :) - can you give me a quick “this is how you build the plugin on Linux” instructions please.

clearly it will start with “git clone, switch to the right branch and then….” some commands ….

Here are some steps:

git clone git checkout issue_rpl-36_child-groups ./gradlew clean build

That PR is under development and may include some changes in the future.

Regards!

rac...@rundeck.com

unread,
Nov 5, 2024, 11:59:28 AMNov 5
to rundeck-discuss
Now, regarding this issue (same host in different groups). That needs another plugin improvement, Rundeck internally uses a list data type to store elements that don't admit the same element in the list and recognize only the last addition (group). This issue is still under investigation.

Greetings!

Jim Richard

unread,
Nov 5, 2024, 12:02:07 PMNov 5
to rundeck-discuss
understood and thank you.

Jim Richard

unread,
Nov 15, 2024, 11:07:45 PMNov 15
to rundeck-discuss
I just built from main giving me version 4.0.6-SNAPSHOT
and it appears to be working, groups/tags happening as expected

Reply all
Reply to author
Forward
0 new messages