Is there a way to set a different container image ...
# ask-the-community
x
Is there a way to set a different container image to all the tasks of a sub-workflow instead of the main workflow’s task container image? Currently, I can only manually set the container image to each task of the sub-workflow explicitly via
ImageSpec
.
d
Sorry if you have already tried this, but what about setting
container_image
for each Task which is part of the subworkflow? https://docs.flyte.org/en/latest/user_guide/customizing_dependencies/multiple_images_in_a_workflow.html#multi-images Does it make sense?
x
Thanks for the quick tip! I was hoping for a solution to set it once and apply to every task implicitly, but this is not exactly but probably closest solution to it. Is there a way to set the images programmatically instead of using pyflyte CLI like:
Copy code
pyflyte run --remote --image mindmeld="ghcr.io/flyteorg/flytecookbook:core-latest" --image borebuster="ghcr.io/flyteorg/flytekit:py3.9-latest" multi_images.py multi_images_wf
d
@Xinzhou Liu maybe using PodTemplates is what you're looking for?