Reputation: 15558
When I excute command to add a connection uri in Airflow, it echo the username and password:
airflow connections add 'example_db' \
--conn-uri 'postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/example_db'
Airflow logs:
Successfully added `conn_id`=example_db : postgresql://username:userpassword@postgres:5432/example_db
How do I mute this output? I don't want userpassword
logged from the environment variable.
Upvotes: 1
Views: 304
Reputation: 8483
I'm not aware of any Airflow settings or configs to accomplish this, but you could pipe these commands to /dev/null
Example
airflow connections add 'example_db' --conn-uri \
'postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/example_db' \
> /dev/null
Upvotes: 1