how to get docker-compose to use the latest image from repository

后端 未结 10 1498
栀梦
栀梦 2021-01-30 07:51

I don\'t know what I\'m doing wrong, but I simply cannot get docker-compose up to use the latest image from our registry without first removing the old containers f

10条回答
  •  無奈伤痛
    2021-01-30 08:32

    To get the latest images use docker-compose build --pull

    I use below command which is really 3 in 1

    docker-compose down && docker-compose build --pull && docker-compose up -d

    This command will stop the services, pulls the latest image and then starts the services.

提交回复
热议问题