# awx (19.5) fresh install by awx-operator (0.15.0) does not connect to external DB

**URL:** <https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216>\
**Category:** AWX Project\
**Tags:** kubernetes, awx\
**Created:** [January 18, 2022, 11:14am UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216 "2022-01-18T11:14:35Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![JS\_G](https://avatars.discourse-cdn.com/v4/letter/j/f475e1/32.png) [@JS\_G](https://forum.ansible.com/u/JS_G)\
**Post date:** [January 18, 2022, 11:14am UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/1 "2022-01-18T11:14:35Z")

</div>

Hello,

I have a problem with AWX installation by awx-operator on kubernetes with external database (postgres).

Awx is deployed, but they are no database connection.

Secret for database is OK, i verified that with psql command, and i connect from awx-task container on database, so flux and credentials are OK.

But when awx is deploy, no connection appears in tcpdump from postgres VM on postgres port.

AWX still restart and displaying Migration step x/30 …

No more log …

Can you help me ?

- awx-operator : 0.15.0
- awx : 19.5.0
- postgres : 12.9
- kubernetes : 1.20.6  
Regards,

---

<div class="post-metadata">

**Author:** ![JS\_G](https://avatars.discourse-cdn.com/v4/letter/j/f475e1/32.png) [@JS\_G](https://forum.ansible.com/u/JS_G)\
**Post date:** [January 18, 2022, 12:52pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/2 "2022-01-18T12:52:06Z")

</div>

Ok, i found my problem

It’s syntax problem on AUTH\_LDAP\_SERVER\_URI

File “/etc/tower/settings.py”, line 75  
AUTH\_LDAP\_SERVER\_URI = ldap://…  
^  
SyntaxError: invalid syntax

This blocks the deployment, without error message

Regards,

---

<div class="post-metadata">

**Author:** ![JS\_G](https://avatars.discourse-cdn.com/v4/letter/j/f475e1/32.png) [@JS\_G](https://forum.ansible.com/u/JS_G)\
**Post date:** [January 18, 2022, 1:16pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/3 "2022-01-18T13:16:05Z")

</div>

What is good syntaxe for protect extra\_settings in awx yaml file ?  
Because I protect variable by ’ or ", and i always have a syntaxe error …

Regards,

---

<div class="post-metadata">

**Author:** ![Tchello\_Mello](https://avatars.discourse-cdn.com/v4/letter/t/bc79bd/32.png) [@Tchello\_Mello](https://forum.ansible.com/u/Tchello_Mello)\
**Post date:** [January 19, 2022, 8:32pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/4 "2022-01-19T20:32:02Z")

</div>

Hello Guy,

I’m not totally sure you meant by protected, you if you want to mount a YAML file then the best way is to create a configmap and then mount it.

Look for the extra\_volume configuration on the documentation so you can see an example of how to mount it.

---

<div class="post-metadata">

**Author:** ![JS\_G](https://avatars.discourse-cdn.com/v4/letter/j/f475e1/32.png) [@JS\_G](https://forum.ansible.com/u/JS_G)\
**Post date:** [January 20, 2022, 4:52pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/5 "2022-01-20T16:52:18Z")

</div>

Hello,

OK I will try that 🙂  
My first try was to use extra\_sttings in spec section from yaml file directly.  
This is describe here : [https://github.com/ansible/awx-operator#extra-settings](https://github.com/ansible/awx-operator#extra-settings)

Regards,

---

<div class="post-metadata">

**Author:** ![JS\_G](https://avatars.discourse-cdn.com/v4/letter/j/f475e1/32.png) [@JS\_G](https://forum.ansible.com/u/JS_G)\
**Post date:** [January 27, 2022, 1:02pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/6 "2022-01-27T13:02:58Z")

</div>

Hello all,

I have found a good syntax for extra\_settings in spec section from yaml file directy :

For the record, although using YAML block quoting works:

spec: extra\_settings:

- setting: AUTH\_LDAP\_BIND\_DN  
value: \>-  
“cn=admin,dc=example,dc=com”

Thanks at @HarishaAmeen who explain that on [https://github.com/ansible/awx-operator/issues/509](https://github.com/ansible/awx-operator/issues/509)  
That should be in the README …

Regards,

---

<div class="post-metadata">

**Author:** ![Infinite\_Trojan](https://avatars.discourse-cdn.com/v4/letter/i/5f9b8f/32.png) [@Infinite\_Trojan](https://forum.ansible.com/u/Infinite_Trojan)\
**Post date:** [February 6, 2022, 10:16pm UTC](https://forum.ansible.com/t/awx-19-5-fresh-install-by-awx-operator-0-15-0-does-not-connect-to-external-db/36216/7 "2022-02-06T22:16:33Z")

</div>

Thank you; this helped in the test instance.  
I am deploying a new instance for devel, I am a newbie when it comes to Kubernetes, if possible can you please guide me what changes I need to make in awx-demo.yaml file to connect to external DB?  
a sample ymal file would be great.  
Well, document is also really ugly; they have given a very basic; bare minimal documentation which doesn’t say whether we have to make changes in awx-operator or awx.demo.yaml or when to to do changes… for eg below changes for external DB.
