-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docker-compose up assumes --no-build #1679
Comments
|
I can't seem to replicate it now which is odd. Will update if it repeats. |
I had the same problem with django: changing it to web: makes it work |
Don't see what would be wrong with the 1st one. |
I also had the error if I manually delete a container which is part of the docker-compose set with the docker command. |
This is how I am able to reproduce it every time. $ mkdir mycont
$ echo "FROM busybox" > mycont/Dockerfile
$ echo -e "mycont:\n build: mycont/" > docker-compose.yml
Building mycont...
# output, press ctrl + c to stop container
$ echo "ENV foo bar" >> mycont/Dockerfile
$ docker-compose up
Recreating test_mycont_1... the container mycont is not rebuild, even though the Dockerfile has changed. I've installed docker-compose using pip. Version information: $ docker-compose -v │ 38 RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
docker-compose version: 1.3.3 │ 39
CPython version: 2.7.6 │ 40 # Create user
OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014 |
@dnephin I re-read your comment above:
So if my image exists (because I ran |
@thewilli We've discussed alternative approaches, including always building and never building. |
I'm seeing the same behavior as reported by the OP.
I just added a new service to a
I didn't pass This behavior is unexpected, as
|
I just hit this myself as well when I went and changed a service from |
@dnephin Actually, I was mistaken. I did the same thing as you - I changed an existing service from |
Thanks very much for the fix! But is there a workaround for this? I'd upgrade compose, but I'm currently stuck using an older version due to #17804 |
It seems if I try to run docker-compose up with a yml that uses
build: .
and the image does not already exist, it acts like --no-build is passed.This is on version 1.3.1
The text was updated successfully, but these errors were encountered: