A Docker image to seed your Mongo database.
Docker image to seed your mongo database with ease. Available on Docker Hub
$ docker pull stefanwalther/mongo-seed[:<version>]
version: '3.3'
services:
mongo:
image: mongo
container_name: mongo
ports:
- 27017:27017
mongo-seed:
image: stefanwalther/mongo-seed
container_name: mongo-seed
environment:
- MONGODB_HOST=mongo
- MONGODB_PORT=27017
volumes:
- ./config/db-seed:/data
depends_on:
- mongo
command: [
"mongoimport --host mongo --port 27017 --db sammlerio --mode upsert --type json --file /data/auth-service~~user.json --jsonArray"
]
Stefan Walther
- twitter/waltherstefan
- github.com/stefanwalther
- stefanwalther.io - Private blog
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue. The process for contributing is outlined below:
- Create a fork of the project
- Work on whatever bug or feature you wish
- Create a pull request (PR)
I cannot guarantee that I will merge all PRs but I will evaluate them all.
MIT
This file was generated by verb-generate-readme, v0.6.0, on March 26, 2019.