compose.yml
file, which looks like this:
version: \'2\'
services:
discovery-microservice:
build: discovery-microservice
context: /discov
Also make sure you have context and dockerfile at the same identation. I made a mistake and was stuck for hours.
My error was
ERROR: yaml.scanner.ScannerError: mapping values are not allowed here in "./docker-compose.yml", line 6, column 19
Wrong:
version : '3'
services:
test:
build:
context: ./test
dockerfile: Dockerfile.test
image: kpod/test:2020
Right:
version : '3'
services:
test:
build:
context: ./test
dockerfile: Dockerfile.test
image: kpod/test:2020