2

What's wrong with the following spec? (Image parameter is here to tag resulting image).

version: '3'

services:
   foo:
      build:
         image: foo/bar
         dockerfile: Dockerfile
         context: .

System output:

services.foo.build contains unsupported option: 'image'

Versions: docker-compose: 1.14.0; Docker: 17.06.0-ce

1 Answer 1

7

“Image” needs to be at the same level as “build”.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.