Unsupported config option for services: 'pgdb'
DaveJ61 opened this issue · 6 comments
Hi Zander,
I seriously doubt this is an issue with your code but I'm just reaching out for some assistance. I've read countless web pages regarding this problem I'm having but none have been able to solve it.
I have been struggling with docker for a few days now. Installation on linux is far from "simple" and there are version and dependency issues, depending on the linux distro one is using.
Using the docker-compose.yml script in your github repo, I get the following:-
ERROR: Version in "./docker-compose.yaml" is unsupported. You might be seeing this error because you're using the wrong Compose file version. Either specify a supported version (e.g "2.2" or "3.3") and place your service definitions under the
services
key, or omit theversion
key and place your service definitions at the root of the file to use version 1.
For more on the Compose file format versions, see https://docs.docker.com/compose/compose-file/
According to what I have read, Version is now deprecated, so I commented out the Version line, but this throws another error:-
ERROR: The Compose file './docker-compose.yaml' is invalid because:
Unsupported config option for services: 'pgdb`
Installing the docker desktop is easier but I think it also still has problems as a part of it is not functioning. It is also still in beta. If I can't get this going, then I will have to resort to installing and using postgres or mysql on the OS as usual.
The yaml script I am using is exactly the same as yours and I am not posting it below as it is a waste of time. The reason being is that adding code using ctrl-e as above results in all the tabs and whitespace being removed. Why? I don't know, but it is not a browser problem, and it isn't me, I don't think.
Dave
Hi Dave, let me see if I can replicate the problem. What Linux distro you working with?
Hi Zander,
Thanks for the quick response. Apologies for not originally disclosing this but I am running Mint 20.2. The standard repository version of docker didn't work either, so I downloaded it using their .deb packages and Docker's own repository.
The docker-desktop was downloaded from their repo as a package.
Ok I will make a tutorial for installing and setting up Docker in Mint 20.3 take it from there.
Sorry Dave, I can't use Mint on M1 chip in a VM. Ubuntu is very similar, I will do a run through, maybe there is something familiar there.
Hi Zander,
After much diagnosing, reading, googling and fiddling I now have a working docker installation on Linux Mint 20.2.
I followed the directions from the docker website using the directions for Ubuntu Focal and installed docker using their repository. Even then this had issues but I was able to run with elevated privileges using sudo docker run hello-world
without a problem.
I followed docker's instructions for running docker as a standard user but I kept getting the error:-
docker: Cannot connect to the Docker daemon at unix:///run/user/1000/docker.sock. Is the docker daemon running?. See 'docker run --help'.
I had already made myself a member of the docker group using sudo usermod -aG docker $(whoami)
as per instructions but this made no difference. I dug deeper for a while longer, and eventually found an undocumented solution which is caused by the installation process setting the environment variable DOCKER_HOST to unix:///run/user/1000/docker.sock
I corrected this by running the following:-
$ unset DOCKER_HOST
$ rm -rf ~/.docker
After doing this, I was then able to run docker run hello-world
and subsequently docker-compose up
without root privileges.
However, I believe there is an instruction to add export DOCKER_HOST=unix:///run/user/1000/docker.sock
to the .bashrc file. I removed this as every time a new terminal was created, I was back to square one and had to unset the DOCKER_HOST variable.
I think it may still be worthwhile producing a howto tutorial on this because on linux it appears to be subject to pitfalls caused by irregularities and differences of linux distros.
Oh and before I forget, I had to set the version line in the docker-compose.yml file to version: "3.7"
Keep up the good work...!!
Best regards
Dave