[SOLVED] Command to retrieve SMTP Password by airflow

Issue

This Content is from Stack Overflow. Question asked by lohith devapatla

How to retrieve SMTP password by airflow using smtp_password_cmd value?

I have added all the environment variables in composer environment which intern overrides airflow configuration.

https://i.stack.imgur.com/n00HE.jpg (Refer this image)

Please give me a brief understanding of what command need to add in composer environment, so that it airflow uses this command to get the value of password?



Solution

As stated in this SO post, it is better to use Secret Manager for this purpose. To use a secret stored in Secret Manager to retrieve an SMTP password, you can follow this documentation.

Posting this as a wikianswer for the benefit of the community as well.


This Question was asked in StackOverflow by lohith devapatla and Answered by Anjela B It is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?