Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REVIEW] Feature/docker #106

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

rosscdh
Copy link

@rosscdh rosscdh commented Oct 9, 2020

make this great app runnable by docker

Ross Crawford-d'Heureuse added 2 commits October 9, 2020 14:42
@plantroon
Copy link

This PR is quite old, but nowadays it is possible to initialize MongoDB docker like this:

  • docker-compose.yaml:
...
  mongodb:
    image: mongo
    volumes:
    - mongo-data:/data/db
    - ./mongo-init.js:/docker-entrypoint-initdb.d/mongo-init.js:ro
...
  • mongo-init.js:
db.createUser(
        {
            user: process.env.MONGO_INITDB_ROOT_USERNAME,
            pwd: process.env.MONGO_INITDB_ROOT_PASSWORD,
            roles: [
                {
                    role: "readWrite",
                    db: process.env.MONGO_INITDB_DATABASE
                }
            ]
        }
);

The comment in env.sample and instructions in README.md should also say mongosh instead of mongo.

@oSumAtrIX
Copy link

OP is absent from GitHub. I recommend taking over the PR.

@rosscdh
Copy link
Author

rosscdh commented Jan 8, 2024 via email

@andrewperry
Copy link

This would be awesome (still!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants