0

Looking into the best practice way of joining a RHEL7 to AD using Ansible. Is there an ansible module to do this? I had a look but there doesn't appear to be.

This article "How to join RHEL system to Active Directory domain using adcli" from Redhat seems like the way to go, but is it the best method to use when implemening with Ansible using the command module?

If the above is the best way, is there a way to ensure idempotence? The command module has a option called creates but this doesn't seem like the most eloquent way.

Thanks for any pointers/suggestions.

hokeycokey
  • 243
  • 1
  • 4
  • 11

1 Answers1

0

Take a look at this ansible role. Using the command or shell module seems to be best option. In the linked repository you can find examples for the creates parameter. Which is the common way to ensure idempotence.

Henrik Pingel
  • 9,380
  • 2
  • 28
  • 39