The following instructions for enabling Azure SSO for Apache Airflow nearly take you all the way - but fall short a couple of details around the configuration of airflow itself:
https://objectpartners.com/2021/12/24/enterprise-auth-for-airflow-azure-ad
All the "Azure" instructions there can be safely followed - the resulting webserver_config.py
(which can be injected into a dockerised Airflow in /opt/airflow/webserver_config.py
) can be built from the following:
from __future__ import annotations
import os