Skip to content

Conversation

@andygrunwald
Copy link
Contributor

Each ansible execution, this task is marked as changed.
In my usecase, I don't want to have docker_image.force_source enforced.

This PR makes this setting configurable.
The change is backwards compatible.

@mhutter mhutter self-assigned this Mar 27, 2022
@mhutter
Copy link
Owner

mhutter commented Mar 28, 2022

What's the purpose of this feature? If you do not want to force pulls, just disable container_docker_pull. The image will still be pulled when the container is started.

@andygrunwald
Copy link
Contributor Author

The usecase would be:

  • During ansible execution you want that the image is being pulled, but not if the image is already present at the machine (I am using version tags and not :latest).
  • I want to ensure that the image is always present BEFORE systems is starting the service

On top of this:
If I want to execute this via CI to ensure changes like "If I would execute this, will there be a change?", this force setting would always say "Who knows?"

@mhutter
Copy link
Owner

mhutter commented Mar 29, 2022

Ah I see, makes sense

@mhutter mhutter merged commit 4e13b96 into mhutter:master Mar 29, 2022
@andygrunwald andygrunwald deleted the make-docker-pull-force-configurable branch March 29, 2022 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants