# LDAPS with Ansible AWX

**URL:** <https://forum.ansible.com/t/ldaps-with-ansible-awx/34034>\
**Category:** AWX Project\
**Tags:** awx\
**Created:** [October 14, 2020, 5:43pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034 "2020-10-14T17:43:43Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Daniel2](https://avatars.discourse-cdn.com/v4/letter/d/b2d939/32.png) [@Daniel2](https://forum.ansible.com/u/Daniel2)\
**Post date:** [October 14, 2020, 5:43pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/1 "2020-10-14T17:43:43Z")

</div>

I have a requirement to have Ansible work with LDAPS.

I have gone into the GUI and put in the correct address for LDAPS. Did not work.

I found a technical support article at RedHat that provided more to do with changing an LDAP.conf file and putting the LDAP server PEM key, did not work.

Did the same to an Ansible TOWER server that I had spun up with an EVAL license, it worked with the same steps as above.

Anyone here configure LDAPS for AWX and it works?

Thank you.

---

<div class="post-metadata">

**Author:** ![Michael\_Dekmetzian](https://avatars.discourse-cdn.com/v4/letter/m/d07c76/32.png) [@Michael\_Dekmetzian](https://forum.ansible.com/u/Michael_Dekmetzian)\
**Post date:** [October 15, 2020, 12:53am UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/2 "2020-10-15T00:53:00Z")

</div>

I do, though it works the same for me in AWX as it does in Tower.

---

<div class="post-metadata">

**Author:** ![Daniel2](https://avatars.discourse-cdn.com/v4/letter/d/b2d939/32.png) [@Daniel2](https://forum.ansible.com/u/Daniel2)\
**Post date:** [October 20, 2020, 4:14pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/3 "2020-10-20T16:14:35Z")

</div>

What did you to to configure LDAPS? I have LDAP working, not secure LDAP (LDAPS).

---

<div class="post-metadata">

**Author:** ![Wei-Yen\_Tan](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/wei-yen_tan/32/4111_2.png) [@Wei-Yen\_Tan](https://forum.ansible.com/u/Wei-Yen_Tan)\
**Post date:** [October 20, 2020, 5:19pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/4 "2020-10-20T17:19:39Z")

</div>

Yoy have to create certificate In the base build of awx.

---

<div class="post-metadata">

**Author:** ![Wei-Yen\_Tan](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/wei-yen_tan/32/4111_2.png) [@Wei-Yen\_Tan](https://forum.ansible.com/u/Wei-Yen_Tan)\
**Post date:** [October 21, 2020, 5:07am UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/5 "2020-10-21T05:07:03Z")

</div>

No that’s not how it works. Awx does it for you at build time. In the inventory file there is a variable you Put the cert in.

---

<div class="post-metadata">

**Author:** ![Rajiv\_Kamath](https://avatars.discourse-cdn.com/v4/letter/r/e5b9ba/32.png) [@Rajiv\_Kamath](https://forum.ansible.com/u/Rajiv_Kamath)\
**Post date:** [October 23, 2020, 3:31pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/6 "2020-10-23T15:31:49Z")

</div>

i got it to work after installation. 2 things need to happen

- ca cert files need to be dropped into /etc/pki/ca-trust/source/anchors and then run “update-ca-trust extract” from within awx\_web. To do this automatically, you might need to run docker-compose up -d again so that the containers are recreated. Make sure you drop the ca files into the directory on the Server where you specified the ca\_files\_dir during initial install.
- if the containers are running centos8 you ll might need to downgrade openssl security level incase the remote ldaps endpoint isnt hardened.  
do a find under /etc for openssl.config and opensslcnf.config and change seclevel=2 to seclevel=1.

---

<div class="post-metadata">

**Author:** ![Rajiv\_Kamath](https://avatars.discourse-cdn.com/v4/letter/r/e5b9ba/32.png) [@Rajiv\_Kamath](https://forum.ansible.com/u/Rajiv_Kamath)\
**Post date:** [October 23, 2020, 3:34pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/7 "2020-10-23T15:34:19Z")

</div>

i edited the docker-compose and downloaded the 2 openssl files \> edited them \> and added them as a volume to the awx\_web container. Run the docker-compose up -d after all the changes and it should work.

---

<div class="post-metadata">

**Author:** ![Wei-Yen\_Tan](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/wei-yen_tan/32/4111_2.png) [@Wei-Yen\_Tan](https://forum.ansible.com/u/Wei-Yen_Tan)\
**Post date:** [October 23, 2020, 3:35pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/8 "2020-10-23T15:35:55Z")

</div>

You should not have to edit the docker compose file at all. The ansible playbook templates it all for you when you run the playbook

---

<div class="post-metadata">

**Author:** ![Rajiv\_Kamath](https://avatars.discourse-cdn.com/v4/letter/r/e5b9ba/32.png) [@Rajiv\_Kamath](https://forum.ansible.com/u/Rajiv_Kamath)\
**Post date:** [October 23, 2020, 4:24pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/9 "2020-10-23T16:24:40Z")

</div>

yes. but the scenario i mentioned was after installation of the awx platform. Not sure if a reinstall would destroy existing configs and data.

---

<div class="post-metadata">

**Author:** ![Wei-Yen\_Tan](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/wei-yen_tan/32/4111_2.png) [@Wei-Yen\_Tan](https://forum.ansible.com/u/Wei-Yen_Tan)\
**Post date:** [October 23, 2020, 4:32pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/10 "2020-10-23T16:32:58Z")

</div>

IIRC when i did my installation it didnt…and after using the Redhat-cop Tower Configuration at

[https://github.com/redhat-cop/tower\_configuration](https://github.com/redhat-cop/tower_configuration)

ALL my tower configuration is listed as code. And can be ‘reapplied’ at any time. In fact what I do is to use yaml datastructures and playbooks to drive the tower configuration.

---

<div class="post-metadata">

**Author:** ![Rajiv\_Kamath](https://avatars.discourse-cdn.com/v4/letter/r/e5b9ba/32.png) [@Rajiv\_Kamath](https://forum.ansible.com/u/Rajiv_Kamath)\
**Post date:** [October 23, 2020, 4:44pm UTC](https://forum.ansible.com/t/ldaps-with-ansible-awx/34034/11 "2020-10-23T16:44:50Z")

</div>

Not sure if my previous reply posted properly so doing it again.  
The scenario i mentioned was post installation. Not sure if a reinstall would have preserved data and configs on the existing awx instance. so far my upgrades arent preserving data.
