Giter VIP home page Giter VIP logo

mongosh-docker's Introduction

MongoDB Shell Docker Image

A compact mongosh Docker image based on bitnami/minideb base image.

For interactive usage only. No bells and whistles included.

Usage

This image is available as docker.io/aeron/mongosh and ghcr.io/Aeron/mongosh. You can use them both interchangeably.

docker pull docker.io/aeron/mongosh
# …or…
docker pull ghcr.io/aeron/mongosh

Interactive Mode (Docker)

Run a container and pass a Mongo URI string, like the following:

docker run -it --rm aeron/mongosh:latest -- $MONGO_URI
# …or…
docker run -it --rm aeron/mongosh:latest -- mongodb://127.0.0.1:27017

Any CLI options mongosh supports could be provided alike:

docker run -it --rm aeron/mongosh:latest -- $MONGO_URI \
    --nodb \
    --eval 'disableTelemetry()'

Interactive Mode (Kubernetes)

Run a container inside a Kube cluster in a similar manner:

kubectl run mongosh --rm --tty -i --restart=Never \
    --image aeron/mongosh:latest -- $MONGO_URI

CLI options and everything else is the same here.

Daemon Mode

Nope, not going to happen. It’s not the purpose of this image.

If you actually need it, feel free to use this image as a basis. Then you need to install the coreutils package and change Dockerfile’s entrypoint directive to ["sleep" "infinity"].

Or use a different image that allows that. It’d be more painless, probably.

Acknowledgment

The mongosh is an open-source project made by MongoDB Inc and its contributors, available under Apache 2.0 license.

mongosh-docker's People

Contributors

aeron avatar dependabot[bot] avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.