Skip to content

Instantly share code, notes, and snippets.

@alexishida
Created April 16, 2018 23:17
Show Gist options
  • Select an option

  • Save alexishida/5e549143d86e66ceeea29cf20ed27266 to your computer and use it in GitHub Desktop.

Select an option

Save alexishida/5e549143d86e66ceeea29cf20ed27266 to your computer and use it in GitHub Desktop.
Docker mongodb
docker run -d \
--name=mongodb \
--restart=always \
-p 27017:27017 \
-v /etc/localtime:/etc/localtime:ro \
-v /storage/mongodb:/data/db \
mongo:latest
# Link
https://hub.docker.com/_/mongo/
docker run -it --rm \
--name mongo-express \
--link web_db_1:mongo \
-p 8081:8081 \
-e ME_CONFIG_OPTIONS_EDITORTHEME="ambiance" \
-e ME_CONFIG_BASICAUTH_USERNAME="user" \
-e ME_CONFIG_BASICAUTH_PASSWORD="fairly long password" \
mongo-express
# Link
https://hub.docker.com/_/mongo-express/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment