$ cat docker-compose.override.yml
version: "3"
services:
nodeos:
volumes:
- nodeos-data-volume:/opt/eos/bin/data-dir
- ./config2.ini:/opt/eos/bin/data-dir/config.ini
$ docker-compose up
ERROR: The Compose file is invalid because:
Service nodeos has neither an image nor a build context specified. At least one must be provided.
$ git rev-parse HEAD
c2869543c687da6e225b2c93b6ac5e17311b0d38
It's as described by the error message, your docker-compose is missing image or build:context:. You need to specify the image or specify where to build the image from, so the docker can know from which image it can build the container.
If you are trying to override the existing docker-compose.yml, ensure that you put the docker-compose.override.yml in the same folder as docker-compose.yml and run the above command from the same folder
Most helpful comment
It's as described by the error message, your docker-compose is missing
imageorbuild:context:. You need to specify the image or specify where to build the image from, so the docker can know from which image it can build the container.If you are trying to override the existing docker-compose.yml, ensure that you put the docker-compose.override.yml in the same folder as docker-compose.yml and run the above command from the same folder