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

Support mongodb authentication #219

Open
runephilosof-abtion opened this issue Aug 14, 2024 · 1 comment
Open

Support mongodb authentication #219

runephilosof-abtion opened this issue Aug 14, 2024 · 1 comment

Comments

@runephilosof-abtion
Copy link

runephilosof-abtion commented Aug 14, 2024

I tried enabling authentication on mongodb and included it in mongodb_url=mongodb://username:password@mongodb:27017/' but got this error

MongoServerError: Command createIndexes requires authentication
    at Connection.onMessage (/node_modules/mongodb/lib/cmap/connection.js:201:30)
    at MessageStream.<anonymous> (/node_modules/mongodb/lib/cmap/connection.js:59:60)
    at MessageStream.emit (node:events:517:28)
    at MessageStream.emit (node:domain:489:12)
    at processIncomingData (/node_modules/mongodb/lib/cmap/message_stream.js:124:16)
    at MessageStream._write (/node_modules/mongodb/lib/cmap/message_stream.js:33:9)
    at writeOrBuffer (node:internal/streams/writable:392:12)
    at _write (node:internal/streams/writable:333:10)
    at Writable.write (node:internal/streams/writable:337:10)
    at Socket.ondata (node:internal/streams/readable:809:22)
    at Socket.emit (node:events:517:28)
    at Socket.emit (node:domain:489:12)
    at addChunk (node:internal/streams/readable:368:12)
    at readableAddChunk (node:internal/streams/readable:341:9)
    at Readable.push (node:internal/streams/readable:278:10)
    at TCP.onStreamRead (node:internal/stream_base_commons:190:23)
@cpwallah
Copy link

hi @runephilosof-abtion this happens in 2 cases majorly 1st you did not do error handling in codes and 2nd connection permission issue as you allow only specific access try these 2 thing i am sure that your error will get sorted

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

No branches or pull requests

2 participants