Comments (11)
I am experiencing the same issue. As a temporary workaround, I will be using the previous version mongo-express:0.54
instead of the :latest
image.
from mongo-express-docker.
I had the same issue at first and saw the the default environment variables changed with the new release. Instead of passing the mongo connection credentials as individual variables, I passed them in the connection string in order to get them working.
Configuration:
environment:
ME_CONFIG_MONGODB_URL: mongodb://root:xxx@mongo:27017
ME_CONFIG_BASICAUTH_USERNAME: root
ME_CONFIG_BASICAUTH_PASSWORD: XXX
from mongo-express-docker.
I use version mongo-express:0.54 instead of the :latest image.
from mongo-express-docker.
As said previously, this is an example of working configuration :
version: '3.1'
services:
mongo:
image: mongo
restart: always
environment:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: example
mongo-express:
image: mongo-express
restart: always
ports:
- 8081:8081
environment:
ME_CONFIG_MONGODB_URL: "mongodb://root:example@mongo:27017/"
ME_CONFIG_MONGODB_ADMINUSERNAME: root
ME_CONFIG_MONGODB_ADMINPASSWORD: example
from mongo-express-docker.
Thanks @weibell downgrading worked for usage with secrets since I can't use the url method.
from mongo-express-docker.
I use version mongo-express:0.54 instead of the :latest image.
It`s works for me.
from mongo-express-docker.
@cgrio I used that 0.54 tag and it did not work for me, actually tried all the tags for the official image and they all give the same error. Anyone has an Idea how to resolve this issue?
from mongo-express-docker.
official image an
I have been using this:
version: '3.7'
services:
mongo:
image: mongo
restart: always
command: mongod --auth
environment:
#MONGO_INITDB_DATABASE: "{{DBNAME}}"
MONGO_INITDB_ROOT_USERNAME: {{USER}}
MONGO_INITDB_ROOT_PASSWORD: {{PASSWORD}}
ports:
- "27017:27017"
volumes:
- mongo_db:/data/db
mongo-express:
image: mongo-express
restart: always
ports:
- 8081:8081
environment:
ME_CONFIG_MONGODB_ADMINUSERNAME: {{USER}}
ME_CONFIG_MONGODB_ADMINPASSWORD: {{PASSWORD}}
#ME_CONFIG_MONGODB_DATABASE: "{{DBNAME}}"
ME_CONFIG_MONGODB_URL: "mongodb://{{USER}}:{{PASSWORD}}@mongo:27017/"
volumes:
mongo_db: {}
networks:
default:
external: true
name: portainer
from mongo-express-docker.
It worked for me only when I added depends_on as follows:
version: '3'
services:
mongodb:
image: mongo
ports:
- 27017:27017
environment:
- MONGO_INITDB_ROOT_USERNAME=admin
- MONGO_INITDB_ROOT_PASSWORD=password
mongo-express:
image: mongo-express
ports:
- 8081:8081
depends_on:
- "mongodb"
environment:
- ME_CONFIG_MONGODB_ADMINUSERNAME=admin
- ME_CONFIG_MONGODB_ADMINPASSWORD=password
- ME_CONFIG_MONGODB_SERVER=mongodb
from mongo-express-docker.
Doesn't work in March. 2023
version: '3.1'
services:
mongodb:
image: mongo
restart: always
ports:
- 27017:27017
environment:
- MONGO_INITDB_ROOT_USERNAME=admin
- MONGO_INITDB_ROOT_PASSWORD=password
mongo-express:
image: mongo-express
restart: always
ports:
- 8081:8081
depends_on:
- "mongodb"
environment:
- ME_CONFIG_MONGODB_ADMINUSERNAME=admin
- ME_CONFIG_MONGODB_ADMINPASSWORD=password
- ME_CONFIG_MONGODB_SERVER=mongodb
from mongo-express-docker.
I mean, this seems to be a pretty major bug and/or big oversight, since one of the most basic thing is to be able to wait for a service to start and only then start the one depending on it right? I just started using Docker and this thing actually worked in an earlier version from what I saw, or at least mongo-express tried to reconnect by itself until mongo has finished initializing.
How can this even go wrong and not to be solved for this long? This kind of questions the whole existence of docker-compose if it doesn't work reliably.
Anyone had some success with the new 'condition' attribute?
edit:
adding restart: unless-stopped
to the mongo-express service seems to do the trick (for now), but I still don't know if this solves the core issue or just somehow works until the next minor version bump.
from mongo-express-docker.
Related Issues (20)
- Pagination Appears to be Broken in Latest Build HOT 3
- "Delete all" broken in latest release HOT 6
- cannot be moved on to the next page HOT 23
- mongo express simple access does not work anymore HOT 10
- Documented configuration is different between GitHub and Docker Hub HOT 3
- Replace `ME_CONFIG_MONGODB_SERVER` with `ME_CONFIG_MONGODB_URL` HOT 4
- Wrong check connection in connecton retry HOT 1
- ATTENTION! ME_CONFIG_BASICAUTH_USERNAME_FILE has stopped working on 1.0.2! HOT 2
- Unable to connect to my MongoDB Atlas cluster HOT 9
- New image does not read env variable ME_CONFIG_MONGODB_SERVER HOT 2
- ME_CONFIG_MONGODB_URL_FILE HOT 2
- Could not connect to database using connectionString HOT 4
- docker entrypoint ignoers ME_CONFIG_MONGODB_SERVER HOT 5
- ME_CONFIG_HEALTH_CHECK_PATH has no effect HOT 4
- HTTP status: 503 Service Unavailable HOT 1
- Not able to run latest mongo-express image with distant mongodb
- Upstream pinning strategy HOT 1
- Move copy down in dockerfile
- Yarn error while building image in Node 18 and 20 HOT 6
- Add build to detect Docker build issues before submitting to stackbrew
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mongo-express-docker.