title: How to force docker-compose to download a new image when using docker hub?
body: <p>I have a docker-compose.yml file which takes the image svka4019/notes2:latest from the docker hub.
  However, if I change the image build it and push it, when I run docker-compose it just uses the one it has already downloaded before.
  Here is the docker-compose.yml:</p>
  <pre><code>springboot-docker-compose-app-container: 
      image: svka4019/notes2:latest
      ports:
        - &quot;80:5001&quot;
      depends_on:
      - friendservice
      networks:
      - mynet
      container_name: base_notes
    friendservice:
      build: ./Pirmas
      command: python app.py
      ports:
      - 5000:5000
      container_name: friend
      networks:
      - mynet
      
  networks:
      mynet:
  </code></pre>
  <p>And the command I use for building and running: <code>docker-compose up --build -d</code>.
  For updating the image in docker-hub I use:</p>
  <pre><code>docker build -t svka4019/notes2
  docker push svka4019/notes2
  </code></pre>
  <p>If I use methods as no-cache it just rebuilds friendService container and skips the base one.</p>