You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2025/06/13 09:42:14 UTC
Re: [PR] Fix `env_file` parameter in Docker operator to load environment variables from file [airflow]
potiuk commented on PR #51500:
URL: https://github.com/apache/airflow/pull/51500#issuecomment-2969755451
Actually after looking at it - there is no "error" to fix here.
This is a basic mechanism of airflow that is in place here where you can specify templated variable either as a string (content) or name ending with some extention (`.env` (file) ).
If you look here:
```
template_ext: Sequence[str] = (
".sh",
".bash",
".env",
)
```
When you specify the file as:
```
env_file="file_name.env"
```
Airflow will read the content from the file in the same directory as DAG (you can also override template folder) - see and look for `template_ext` https://airflow.apache.org/docs/apache-airflow/stable/core-concepts/operators.html#concepts-jinja-templating
--
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