Skip to content

Commit

Permalink
Allow DockerOperator's image to be templated (#19997)
Browse files Browse the repository at this point in the history
  • Loading branch information
jedcunningham authored Dec 3, 2021
1 parent 52347b6 commit 1924e29
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions airflow/providers/docker/operators/docker.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class DockerOperator(BaseOperator):
be provided with the parameter ``docker_conn_id``.
:param image: Docker image from which to create the container.
If image tag is omitted, "latest" will be used.
If image tag is omitted, "latest" will be used. (templated)
:type image: str
:param api_version: Remote API version. Set to ``auto`` to automatically
detect the server's version.
Expand Down Expand Up @@ -152,7 +152,7 @@ class DockerOperator(BaseOperator):
:type retrieve_output_path: Optional[str]
"""

template_fields = ('command', 'environment', 'container_name')
template_fields = ('image', 'command', 'environment', 'container_name')
template_ext = (
'.sh',
'.bash',
Expand Down

0 comments on commit 1924e29

Please sign in to comment.