ccadogan-sfld opened a new issue, #65929:
URL: https://github.com/apache/airflow/issues/65929

   ### Under which category would you file this issue?
   
   Task SDK
   
   ### Apache Airflow version
   
   3.2.1
   
   ### What happened and how to reproduce it?
   
   I'm running airflow 3.2.1 in EKS with multi_team mode enabled, and using the 
`EKSPodOperator` to execute DAGs on remote clusters. To do this, I have 
configured aws_default connections using `AIRFLOW_CONN__<TEAM>___<CONN_ID>` 
(e.g. `AIRFLOW_CONN__TEAM_A___AWS_DEFAULT`). However, the `EKSPodOperator` is 
failing. 
   
   I think the issue lies in 
[airflow.sdk.execution_time.context](https://github.com/apache/airflow/blob/main/task-sdk/src/airflow/sdk/execution_time/context.py#L147).
 In `_get_connection`, `SecretCache.get_connection_uri(conn_id)` supports 
passing `team_name`, but is missing the value when retrieving the connection 
info from the env.
   
   
   ---
   Steps to Reproduce:
   
   1. Enable multi-team mode (core.multi_team = true)
   2. Set a team-scoped connection via env var: 
`AIRFLOW_CONN__TEAM_A___AWS_DEFAULT='{"conn_type":"aws","extra":{"role_arn":"..."}}'`
   3. Assign a DAG bundle to myteam
   4. In a DAG, use an operator that looks up aws_default (e.g. EksPodOperator 
which defaults to `aws_conn_id="aws_default"`)
   5. The team-scoped env var is ignored
   
   ### What you think should happen instead?
   
   `AIRFLOW_CONN__` values should be team scoped, (_possibly_) with team scoped 
values taking priority over global values.
   
   ### Operating System
   
   Debian GNU/Linux 12 (bookworm)
   
   ### Deployment
   
   Official Apache Airflow Helm Chart
   
   ### Apache Airflow Provider(s)
   
   _No response_
   
   ### Versions of Apache Airflow Providers
   
   ```
   apache-airflow==3.2.1
   apache-airflow-providers-amazon==9.25.0
   apache-airflow-providers-cncf-kubernetes==10.16.0
   apache-airflow-providers-fab==3.6.1
   ```
   
   ### Official Helm Chart version
   
   1.21.0 (latest released)
   
   ### Kubernetes Version
   
   1.34
   
   ### Helm Chart configuration
   
   _No response_
   
   ### Docker Image customizations
   
   ```
   ❯ cat requirements-frozen.txt 
   # This file was autogenerated by uv via the following command:
   #    uv pip compile pyproject.toml --no-deps --no-annotate
   apache-airflow==3.2.1
   apache-airflow-providers-amazon==9.25.0
   apache-airflow-providers-cncf-kubernetes==10.16.0
   apache-airflow-providers-fab==3.6.1
   boto3==1.42.94
   flask-appbuilder==5.2.1
   mypy-boto3-dynamodb==1.42.73
   ```
   
   --- 
   
   - Okta integration (mostly following 
[this](https://airflow.apache.org/docs/apache-airflow-providers-fab/stable/auth-manager/sso.html))
 in `$AIRFLOW_HOME/webserver_config.py`
   - Custom auth manager using `FabAuthManager`
   
   ### Anything else?
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to