-
|
Hello, I have a problem with implementing Airflow when using Local Filesystem as secret backend. I have a deployment of Airflow 2.5.3 on Openshift using the Helm Chart supplied by the community. I'm using the CeleryExecutor and have a postgres as the metadb. Airflow works fine when Openshift secrets that contain sql_alchemy_conn and fernet_key etc. are supplied as environment variables. The scheduler and webserver pods starts and everything works as intended. When I try to run Airflow using LocalFilesystemBackend the application is unable to connect to the postgres db. The log supplies the following error: I understand from the error that Airflow fails to find the files (or find the variables/connections in them) that are intended as the secret backend. In the helm chart, I updated the airflow.cfg by adding the secret section and specifying what type of backend: I also defined the defined the _secret properties in airflow.cfg, for example the sql_alchemy_conn_secret seen above. Then in values.yaml file I defined the extra volumes for scheduler, webserver, triggerer and worker: During testing I became uncertain whether Airflow treats the properties as variables or connections, so I put all of the properties in both airflow-backend-connections.json and airflow-backend-variables.json: When I access the scheduler pod, I can see that the files and updates to airflow.cfg are there as intended. The files are in place. I set the permission to all to see if that was the issue. Airflow.cfg have the updated properties. When I try to execute command Other actions taken: I am out of ideas of what detail I am missing to make this work and would appreciate any assistance in making Airflow use the Local Filesystem Secret Backend. Regards, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
LocalFilesystemBackend does not support storing config - only connections and variables. You should configure your connections/fernet key differently (directly via K8S secrets for example) - see examples in our production-guide and helm values. |
Beta Was this translation helpful? Give feedback.
LocalFilesystemBackend does not support storing config - only connections and variables.
You should configure your connections/fernet key differently (directly via K8S secrets for example) - see examples in our production-guide and helm values.
https://airflow.apache.org/docs/helm-chart/stable/production-guide.html#kubernetes-secret