You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2020/10/27 15:00:50 UTC

[GitHub] [airflow] VictorGeaGarcia opened a new pull request #11890: Fix Logout Google Auth issue

VictorGeaGarcia opened a new pull request #11890:
URL: https://github.com/apache/airflow/pull/11890


   **WHY?**
   - [prompt functionality](https://developers.google.com/identity/protocols/oauth2/web-server#userconsentprompt) is not implemented in Google Auth implementation. Therefore you cannot log out properly from Airflow.
   
   **SOLUTION:**
   - Config section for Google Auth backend would look like:
   
   [webserver]
   authenticate = True
   auth_backend = airflow.contrib.auth.backends.google_auth
   
   [google]
   client_id = google_client_id
   client_secret = google_client_secret
   oauth_callback_route = /oauth2callback
   domain = example1.com,example2.com
   prompt = <One of : 'consent', 'select_account', 'none' or ''>
   
   closes: #11889
   
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] mik-laj commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
mik-laj commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-720864474


   I am not an expert on non-rbac UI, but I don't understand why it affects logout. Can you give a little more context?


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-717923578


   [The Workflow run](https://github.com/apache/airflow/actions/runs/333588674) is cancelling this PR. Building images for the PR has failed. Follow the the workflow link to check the reason.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] VictorGeaGarcia edited a comment on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
VictorGeaGarcia edited a comment on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-721268823


   Sure @mik-laj , if [no 'prompt' option is specified](https://developers.google.com/identity/protocols/oauth2/web-server), then "the user will be prompted only the first time your project requests access". Therefore, anytime you log out, the logout automatically logs you back in since you don't need to grant permissions or anything. As you can see in the image [here](https://github.com/apache/airflow/issues/11889), when you log out you get logout message but you're again logged-in.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] mik-laj commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
mik-laj commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-717531099


   @ryw it's only for 1.10.  We don't have airflow/contrib/auth/backends package in Airflow 2.0.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] mik-laj merged pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
mik-laj merged pull request #11890:
URL: https://github.com/apache/airflow/pull/11890


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] mik-laj edited a comment on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
mik-laj edited a comment on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-720864474


   I am not a non-RBAC UI expert, but I don't understand why it affects logout. Can you give a little more context?


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] boring-cyborg[bot] commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
boring-cyborg[bot] commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-721652385


   Awesome work, congrats on your first merged pull request!
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] VictorGeaGarcia commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
VictorGeaGarcia commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-717904008


   @ryw  thanks!
   I updated the docs
   
   And yeah as @mik-laj  said this only targets 1.10 since there is no similar package in 2.0 @


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] ryw commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
ryw commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-717310493


   Also, is this a 1.10 only commit, or should it target master?


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] VictorGeaGarcia commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
VictorGeaGarcia commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-721268823


   Sure, if [no 'prompt' option is specified](https://developers.google.com/identity/protocols/oauth2/web-server), then "the user will be prompted only the first time your project requests access". Therefore, anytime you log out, the logout automatically logs you back in since you don't need to grant permissions or anything. As you can see in the image [here](https://github.com/apache/airflow/issues/11889), when you log out you get logout message but you're again logged-in.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] boring-cyborg[bot] commented on pull request #11890: Fix Logout Google Auth issue

Posted by GitBox <gi...@apache.org>.
boring-cyborg[bot] commented on pull request #11890:
URL: https://github.com/apache/airflow/pull/11890#issuecomment-717304773


   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 Contribution Guide (https://github.com/apache/airflow/blob/master/CONTRIBUTING.rst)
   Here are some useful points:
   - Pay attention to the quality of your code (flake8, pylint and type annotations). Our [pre-commits]( https://github.com/apache/airflow/blob/master/STATIC_CODE_CHECKS.rst#prerequisites-for-pre-commit-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/master/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/master/BREEZE.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/master/CONTRIBUTING.rst#coding-style-and-best-practices).
   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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org