Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Cloud Composer 2 unable to send SMTP emails

Hi Team,

I am struggling in sending a email from cloud-composer 2 environment(

composer-2.0.11-airflow-2.2.3) via smtp.gmail.com.
Please find my configs below :
Note I tried using smtp_password_cmd and smtp_password_secret but both give the same error.

I have also setup a network connectivity test which shows smtp.gmail.com is reachable from my VPC

Error Msg:

File "/opt/python3.8/lib/python3.8/smtplib.py", line 310, in _get_socket
return socket.create_connection((host, port), timeout,
File "/opt/python3.8/lib/python3.8/socket.py", line 808, in create_connection
raise err
File "/opt/python3.8/lib/python3.8/socket.py", line 796, in create_connection
sock.connect(sa)
OSError: [Errno 99] Cannot assign requested address

bajpaid_0-1657023865741.png

Any help/pointers would be appreciated.

Thanks

0 3 1,687
3 REPLIES 3