I'm trying to build a docker flink containers using two different ways, through a Dockerfile and also with Docker compose. The Dockerfile works fine, but I'm facing some troubles with the Docker compose.
After a bit of reserach (if I've understood it correctly) when I execute a yml file, docker checks the services that are going to be use, and verifies that the needed images are pulled, If any of them is missing, docker starts the pull process. The problem is that by default, docker pulls the image:latest tag, and I'm interested in a specific tag.
I've tried to pull the image:tag before executing the docker-compose.yml file, but despite that, Docker compose ignores the already pulled image and starts downloading the image:latest tag
There is any mechanism to do that?
I don't know if it's useful for answer the question, but I attach the yml code I've:
version: "2.1"
services:
jobmanager:
image: ${FLINK_DOCKER_IMAGE_NAME:-flink}
expose:
- "6123"
ports:
- "8081:8081"
command: jobmanager
environment:
- JOB_MANAGER_RPC_ADDRESS=jobmanager
taskmanager:
image: ${FLINK_DOCKER_IMAGE_NAME:-flink}
expose:
- "6121"
- "6122"
depends_on:
- jobmanager
command: taskmanager
links:
- "jobmanager:jobmanager"
environment:
- JOB_MANAGER_RPC_ADDRESS=jobmanager
Thank you
Just specify explicitly the image and its tag that you want to use:
jobmanager:
image: <image-name>:<tag>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With