airflow-chart
airflow-chart copied to clipboard
enabling pgbouncer does not work on k3d
tried this chart using k3d
scheduler, worker and webserver are unable to start
stuck waiting for container wait-for-airflow-migrations, which fails with this error
sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) ERROR: No such database: airflow-metadata
after some investigation, i see that the issue is the value for pgbouncer.ini in the airflow-pgbouncer-config secret.
here's what it looks like:
airflow-metadata = host=<no value> dbname=postgres port=5432 pool_size=3
airflow-result-backend = host=<no value> dbname=postgres port=5432 pool_size=2
[pgbouncer]
pool_mode = transaction
listen_port = 6543
server_tls_sslmode = prefer
listen_addr = *
auth_type = md5
auth_file = /etc/pgbouncer/users.txt
stats_users = postgres
ignore_startup_parameters = extra_float_digits
max_client_conn = 100
verbose = 0
log_disconnections = 0
log_connections = 0
the problem is the host=<no value>
if we look up the IP for the pgbouncer service and update the secret, it resolves the issue.
i am not sure if this is specific to k3d.