I have a CentOS 7 instance,and I've installed airflow and postgresql on top of that.
Initially installed the postgres-server and the contrib via yum by following the steps here:
https://www.hostinger.com/tutorials/how-to-install-postgresql-on-centos-7/
upon installation, then I started the postgres service and checked the status whether it's up and running.
After this I installed apache-airflow by using the following command:
pip3 install "apache-airflow[postgresql]==2.3.1" --constraint "https://raw.githubusercontent.com/apache/airflow/constraints-2.3.1/constraints-3.7.txt"
Then followed the steps here to create the airflow user, db via the psql cli.
Finally I updated the airflow.cfg with the correct sqlalchemy conn details:
sql_alchemy_conn = postgresql+psycopg2://airflow:airflow@localhost/airflow
Once I start to run airflow db init it throws me this error:
sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) FATAL: Ident authentication failed for user "airflow"
The pg_hba.conf looks like below:
I could also see the airflow user and the airflow db via psql
Not sure where am I going wrong? Any help could be appreciated.
NOTE: Postgresql version - 9.2.24 || Airflow version - 2.3.1

