You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "1abdelhalim (via GitHub)" <gi...@apache.org> on 2025/09/04 21:31:59 UTC
[PR] Add SSO integration guide for Apache Airflow [airflow]
1abdelhalim opened a new pull request, #55281:
URL: https://github.com/apache/airflow/pull/55281
This PR adds a comprehensive guide for integrating Single Sign-On (SSO) in Apache Airflow using a generic OAuth2 provider. The new documentation (sso_example.rst) includes prerequisites, configuration steps, environment variable setup, troubleshooting tips, and references to official docs. This addresses the lack of SSO setup documentation in Airflow.
Files added/changed:
sso_example.rst (new file with full guide)
Related Issue:
closes: #55276
Checklist:
- [ ] Documentation added
- [ ] PR description follows guidelines
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "1abdelhalim (via GitHub)" <gi...@apache.org>.
1abdelhalim commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3292901594
Fixed
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "eladkal (via GitHub)" <gi...@apache.org>.
eladkal commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2366990886
##########
.github/workflows/ci-amd.yml:
##########
@@ -139,6 +139,10 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
+ - name: "Install gh and jq"
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y gh jq
Review Comment:
There should be no changes to workflows with this PR
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "vincbeck (via GitHub)" <gi...@apache.org>.
vincbeck commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2368484051
##########
providers/fab/docs/auth-manager/sso.rst:
##########
@@ -0,0 +1,251 @@
+.. Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+.. http://www.apache.org/licenses/LICENSE-2.0
+
+.. Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+.. spelling::
+ word-list::
+ Entra
Review Comment:
Now it is good
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "boring-cyborg[bot] (via GitHub)" <gi...@apache.org>.
boring-cyborg[bot] commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3255798904
Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide (https://github.com/apache/airflow/blob/main/contributing-docs/README.rst)
Here are some useful points:
- Pay attention to the quality of your code (ruff, mypy and type annotations). Our [prek-hooks]( https://github.com/apache/airflow/blob/main/contributing-docs/08_static_code_checks.rst#prerequisites-for-prek-hooks) will help you with that.
- In case of a new feature add useful documentation (in docstrings or in `docs/` directory). Adding a new operator? Check this short [guide](https://github.com/apache/airflow/blob/main/airflow-core/docs/howto/custom-operator.rst) Consider adding an example DAG that shows how users should use it.
- Consider using [Breeze environment](https://github.com/apache/airflow/blob/main/dev/breeze/doc/README.rst) for testing locally, it's a heavy docker but it ships with a working Airflow and a lot of integrations.
- Be patient and persistent. It might take some time to get a review or get the final approval from Committers.
- Please follow [ASF Code of Conduct](https://www.apache.org/foundation/policies/conduct) for all communication including (but not limited to) comments on Pull Requests, Mailing list and Slack.
- Be sure to read the [Airflow Coding style]( https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#coding-style-and-best-practices).
- Always keep your Pull Requests rebased, otherwise your build might fail due to changes not related to your commits.
Apache Airflow is a community-driven project and together we are making it better 🚀.
In case of doubts contact the developers at:
Mailing List: dev@airflow.apache.org
Slack: https://s.apache.org/airflow-slack
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "eladkal (via GitHub)" <gi...@apache.org>.
eladkal commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2366990886
##########
.github/workflows/ci-amd.yml:
##########
@@ -139,6 +139,10 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
+ - name: "Install gh and jq"
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y gh jq
Review Comment:
This is not right. There should be no changes to workflow with this PR
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3289693244
Provisionally approving - assuming that someone wil review and test the configuration that is mentioned in the docs
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "1abdelhalim (via GitHub)" <gi...@apache.org>.
1abdelhalim commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3292451163
Moved
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "eladkal (via GitHub)" <gi...@apache.org>.
eladkal commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2349472529
##########
providers/fab/docs/auth-manager/sso.rst:
##########
@@ -0,0 +1,228 @@
+ .. Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ .. http://www.apache.org/licenses/LICENSE-2.0
+
+ .. Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+The FAB Auth Manager supports Single Sign-On (SSO) through OAuth2 providers.
+This guide shows how to configure SSO with various OAuth2 providers such as
+Google, Okta, Azure Entra ID, and others.
+
+This guide shows how to configure SSO with the FAB Auth Manager using a
+generic OAuth2 provider. The process is similar for providers such as
+Okta, Azure Entra ID, Google, or Auth0.
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Apache Airflow installed and running with FAB Auth Manager
+- Access to an OAuth2 SSO provider (e.g., Google, Okta, Auth0, Azure Entra ID)
Review Comment:
Do we need to cross reference to the docs in these specific providers that are about sso?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3292853481
Need static checks and doc fixing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "eladkal (via GitHub)" <gi...@apache.org>.
eladkal commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2366990886
##########
.github/workflows/ci-amd.yml:
##########
@@ -139,6 +139,10 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
+ - name: "Install gh and jq"
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y gh jq
Review Comment:
This is not right. There should be no changes to workflows with this PR
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "vincbeck (via GitHub)" <gi...@apache.org>.
vincbeck commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2323639083
##########
airflow-core/docs/security/sso_example.rst:
##########
@@ -0,0 +1,81 @@
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+This guide provides a working example and step-by-step instructions for configuring Single Sign-On (SSO) in Apache Airflow using a generic OAuth2 provider. The process is similar for other providers (e.g., Google, Okta, Azure AD, Auth0).
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Airflow 2.x installed and running
+- Access to an OAuth2 SSO provider (e.g., Google, Okta, Auth0, Azure AD)
+- Admin access to Airflow and your SSO provider
+
+Configuration Steps
+-------------------
+
+1. **Install Required Packages**
+
+ Airflow uses Flask AppBuilder (FAB) for authentication. To enable OAuth, install the required provider:
+
+ .. code-block:: bash
+
+ pip install 'apache-airflow[auth,oauth]' # or your specific provider
+
+2. **Configure Airflow for SSO**
+
+ Edit your ``airflow.cfg`` or set environment variables as follows:
+
+ .. code-block:: ini
+
+ [webserver]
Review Comment:
This command no longer exist
##########
airflow-core/docs/security/sso_example.rst:
##########
@@ -0,0 +1,81 @@
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+This guide provides a working example and step-by-step instructions for configuring Single Sign-On (SSO) in Apache Airflow using a generic OAuth2 provider. The process is similar for other providers (e.g., Google, Okta, Azure AD, Auth0).
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Airflow 2.x installed and running
+- Access to an OAuth2 SSO provider (e.g., Google, Okta, Auth0, Azure AD)
+- Admin access to Airflow and your SSO provider
+
+Configuration Steps
+-------------------
+
+1. **Install Required Packages**
+
+ Airflow uses Flask AppBuilder (FAB) for authentication. To enable OAuth, install the required provider:
Review Comment:
This is not true. Airflow delegates authentication to auth manager. These auth managers, which can be viewed as plugins, are responsible for authentication and authorization. I think you are referring to Fab auth manager. In that case, I'd advise you to create this doc in the Fab provider.
##########
airflow-core/docs/security/sso_example.rst:
##########
@@ -0,0 +1,81 @@
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+This guide provides a working example and step-by-step instructions for configuring Single Sign-On (SSO) in Apache Airflow using a generic OAuth2 provider. The process is similar for other providers (e.g., Google, Okta, Azure AD, Auth0).
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Airflow 2.x installed and running
Review Comment:
Is it for Airflow 2 only? If so, it should be in the docs, whether we put here is for Airflow 3. As a matter of fact we do not mention the Airflow version in docs, we just mention `Airflow`. In Airflow doc website, the user can pick the version with the top left dropdown.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "jroachgolf84 (via GitHub)" <gi...@apache.org>.
jroachgolf84 commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2330269246
##########
airflow-core/docs/security/sso_example.rst:
##########
@@ -0,0 +1,81 @@
+
Review Comment:
I think that this is quite useful, but should include specific examples as well (Okta, Entra ID, etc.).
##########
airflow-core/docs/security/sso_example.rst:
##########
@@ -0,0 +1,81 @@
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+This guide provides a working example and step-by-step instructions for configuring Single Sign-On (SSO) in Apache Airflow using a generic OAuth2 provider. The process is similar for other providers (e.g., Google, Okta, Azure AD, Auth0).
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Airflow 2.x installed and running
+- Access to an OAuth2 SSO provider (e.g., Google, Okta, Auth0, Azure AD)
+- Admin access to Airflow and your SSO provider
+
+Configuration Steps
+-------------------
+
+1. **Install Required Packages**
+
+ Airflow uses Flask AppBuilder (FAB) for authentication. To enable OAuth, install the required provider:
Review Comment:
I also don't believe that the FAB Auth Manager is the default auth manager anymore... It needs to be specified, otherwise I believe it uses the Simple Auth Manager.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "vincbeck (via GitHub)" <gi...@apache.org>.
vincbeck commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2368250676
##########
providers/fab/docs/auth-manager/sso.rst:
##########
@@ -0,0 +1,251 @@
+.. Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+.. http://www.apache.org/licenses/LICENSE-2.0
+
+.. Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+.. spelling::
+ word-list::
+ Entra
Review Comment:
No need
##########
docs/spelling_wordlist.txt:
##########
@@ -606,6 +606,7 @@ encodable
encryptor
enqueue
enqueued
+Entra
Review Comment:
Twice the same word?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "vincbeck (via GitHub)" <gi...@apache.org>.
vincbeck merged PR #55281:
URL: https://github.com/apache/airflow/pull/55281
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "1abdelhalim (via GitHub)" <gi...@apache.org>.
1abdelhalim commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2368467182
##########
providers/fab/docs/auth-manager/sso.rst:
##########
@@ -0,0 +1,251 @@
+.. Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+.. http://www.apache.org/licenses/LICENSE-2.0
+
+.. Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+.. spelling::
+ word-list::
+ Entra
Review Comment:
Ok, thank you so much
I will remove this one
is there any other suggestions to make this pr ready to be merged ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "boring-cyborg[bot] (via GitHub)" <gi...@apache.org>.
boring-cyborg[bot] commented on PR #55281:
URL: https://github.com/apache/airflow/pull/55281#issuecomment-3325143766
Awesome work, congrats on your first merged pull request! You are invited to check our [Issue Tracker](https://github.com/apache/airflow/issues) for additional contributions.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add SSO integration guide for Apache Airflow [airflow]
Posted by "1abdelhalim (via GitHub)" <gi...@apache.org>.
1abdelhalim commented on code in PR #55281:
URL: https://github.com/apache/airflow/pull/55281#discussion_r2349482518
##########
providers/fab/docs/auth-manager/sso.rst:
##########
@@ -0,0 +1,228 @@
+ .. Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ .. http://www.apache.org/licenses/LICENSE-2.0
+
+ .. Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+=============================
+Single Sign-On (SSO) Integration
+=============================
+
+The FAB Auth Manager supports Single Sign-On (SSO) through OAuth2 providers.
+This guide shows how to configure SSO with various OAuth2 providers such as
+Google, Okta, Azure Entra ID, and others.
+
+This guide shows how to configure SSO with the FAB Auth Manager using a
+generic OAuth2 provider. The process is similar for providers such as
+Okta, Azure Entra ID, Google, or Auth0.
+
+.. contents:: Table of Contents
+ :local:
+ :depth: 2
+
+Prerequisites
+-------------
+- Apache Airflow installed and running with FAB Auth Manager
+- Access to an OAuth2 SSO provider (e.g., Google, Okta, Auth0, Azure Entra ID)
Review Comment:
Good one.
Added cross-references to the provider-specific docs in Prerequisites and each example section. Should help users find the setup instructions they need 👍
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org