Last active
October 25, 2020 14:34
-
-
Save bgadrian/ed5a5bacb272ab21eed4760ff4ae0b1a to your computer and use it in GitHub Desktop.
Mongo and mongo-express local dev setup, for meteor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
docker stop mongo-server | |
docker rm mongo-server | |
#start meteor with env variable MONGO_URL=mongodb://localhost:27017/yourDatabase | |
#meteor /db/ path is in .meteor/local/db/ | |
docker run --name mongo-server -it -d \ | |
-v /var/www/mongoData:/data/db \ | |
--net="host" \ | |
--restart=always mongo:3.4.3 | |
docker stop mongo-express | |
docker rm mongo-express | |
#simple admin web UI https://github.com/glittershark/meteor-express | |
#listens on 0:0:0:0:8081 | |
docker run -it --restart=always -d \ | |
--name mongo-express \ | |
--net="host" \ | |
-e ME_CONFIG_OPTIONS_EDITORTHEME="ambiance" \ | |
-e ME_CONFIG_BASICAUTH_USERNAME="" \ | |
-e ME_CONFIG_MONGODB_SERVER="127.0.0.1" \ | |
-e ME_CONFIG_MONGODB_PORT="27017" \ | |
-e ME_CONFIG_BASICAUTH_USERNAME="" \ | |
mongo-express |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment