setup-mongo.sh 304 B

12345678
  1. #!/bin/bash
  2. mongo musare \
  3. --port ${MONGO_PORT} \
  4. -u "admin" \
  5. --authenticationDatabase "admin" \
  6. -p ${MONGO_ROOT_PASSWORD} \
  7. --eval "db.createUser({ user: '${MONGO_USER_USERNAME}', pwd: '${MONGO_USER_PASSWORD}', roles:[ { role:'readWrite', db: 'musare' } ] } );"