Since this discourse seems to just close topics and not reopen them I’m making a new one to help out sudharsan_v in 1054
The issue with ...{“code”:26,“codeName”:“NamespaceNotFound”,“errmsg”:... is because the mongosetup doesn’t seem to work in the docker-compose example. It didn’t for me on Linux trying this out so I took a search and only found this unanswered question.
For posterity of the old web days and trying to help people who search in the future. Go run the mongo setup command manually. You can even remove the entire section from that docker-compose.yml since it doesn’t work properly.
Login to your docker container to run commands with:
docker ps to find the container name
docker exec -it demo-mongodb-1 bash if it’s the default container name
mongosh --host mongodb:27017 to get to the mongo shell
use openflow to use the openflow db
rs.status() likely shows an error with no config
config = {"_id" : "rs0", "members" : [ { "_id" : 0, "host" : "mongodb:27017" } ] }; set the config from whatever mongo needs, the default is 0 replicas in this demo
rs.initiate(config); initiate
rs.status() confirms things are working now
exit (twice) gets you back out to the command line
Now going to http://localhost.openiap.io should no longer give you Bad Gateway if it was just the rs config issue.
You can close this topic, I’m just trying to help… and Allan_Zimmermann if you’re trying to have a nice searchable discourse I’d recommend permitting reopening of topics for just this use case.