{"id":14956812,"url":"https://github.com/aashreys/docker-mongo-auth","last_synced_at":"2025-10-24T10:31:05.363Z","repository":{"id":138636697,"uuid":"96255334","full_name":"aashreys/docker-mongo-auth","owner":"aashreys","description":"Easily setup authentication on Docker's Official MongoDB image. ","archived":false,"fork":false,"pushed_at":"2022-12-08T13:32:09.000Z","size":6,"stargazers_count":84,"open_issues_count":4,"forks_count":61,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-01-29T10:13:44.137Z","etag":null,"topics":["docker-image","dockerfile","mongo","mongodb"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aashreys.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-07-04T21:51:14.000Z","updated_at":"2025-01-20T02:33:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"82dc885f-8793-4685-9659-ad1b22a4c4fb","html_url":"https://github.com/aashreys/docker-mongo-auth","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aashreys%2Fdocker-mongo-auth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aashreys%2Fdocker-mongo-auth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aashreys%2Fdocker-mongo-auth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aashreys%2Fdocker-mongo-auth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aashreys","download_url":"https://codeload.github.com/aashreys/docker-mongo-auth/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237950882,"owners_count":19392667,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker-image","dockerfile","mongo","mongodb"],"created_at":"2024-09-24T13:13:34.570Z","updated_at":"2025-10-24T10:31:00.014Z","avatar_url":"https://github.com/aashreys.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Deprecated\nThis repository is not maintained anymore.\n\n# docker-mongo-auth\nA Docker Image for MongoDB which makes it easy to create an Admin, a Database and a Database User when the container is first launched.\n\n# Customization\nThere are a number of environment variables which you can specify to customize the username and passwords of your users. \n\n- With Dockerfile\n  ```\n  // Auth Configuration.\n  // These environment variables can also be specified through command line or docker-compose configuration\n  # ENV AUTH yes\n\n  # ENV MONGODB_ADMIN_USER root\n  # ENV MONGODB_ADMIN_PASS password\n\n  # ENV MONGODB_APPLICATION_DATABASE your_db\n  # ENV MONGODB_APPLICATION_USER user\n  # ENV MONGODB_APPLICATION_PASS password\n  ```\n  \n- With docker-compose.yml\n  ```\n  services:\n    db:\n      image: aashreys/mongo-auth:latest\n      environment:\n        - AUTH=yes\n        - MONGODB_ADMIN_USER=admin\n        - MONGODB_ADMIN_PASS=admin123\n        - MONGODB_APPLICATION_DATABASE=sample\n        - MONGODB_APPLICATION_USER=aashrey\n        - MONGODB_APPLICATION_PASS=admin123\n      ports:\n        - \"27017:27017\"\n  // more configuration\n  ```\n\n- With command line\n  ```\n  docker run -it \\\n    -e AUTH=yes \\\n    -e MONGODB_ADMIN_USER=admin \\\n    -e MONGODB_ADMIN_PASS=adminpass \\\n    -e MONGODB_APPLICATION_DATABASE=mytestdatabase \\\n    -e MONGODB_APPLICATION_USER=testuser \\\n    -e MONGODB_APPLICATION_PASS=testpass \\\n    -p 27017:27017 aashreys/mongo-auth:latest\n  ```\n\nFind the image on Docker Cloud @ https://cloud.docker.com/swarm/aashreys/repository/docker/aashreys/mongo-auth\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faashreys%2Fdocker-mongo-auth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faashreys%2Fdocker-mongo-auth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faashreys%2Fdocker-mongo-auth/lists"}