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

[Feature]: Support for MongoDB tlsCertificateKeyFile for clients rts, backend server, entrypoint.sh #18409

Open
1 task done
sum35h opened this issue Nov 24, 2022 · 2 comments
Assignees
Labels
Backend This marks the issue or pull request to reference server code Enhancement New feature or request Integrations Product Issues related to a specific integration Mongo Issues related to Mongo DB plugin Query & JS Pod Issues related to the query & JS Pod

Comments

@sum35h
Copy link
Contributor

sum35h commented Nov 24, 2022

Is there an existing issue for this?

  • I have searched the existing issues

Summary

Currently Appsmith does not support connection to custom mongoDB with the SSL since the java driver does not support the tls keys specified in the MongoDB URI.
APPSMITH_MONGODB_URI="mongodb://<usr>:<pwd>@sandbox-mongo.appsmith.com/appsmith?authSource=admin&tls=true&tlsCAFile=/appsmith-stacks/rootCA.pem&tlsCertificateKeyFile=/appsmith-stacks/mongodb.pem"

logs


test-backup-restore-atlas | backend stdout | [2022-11-24 04:55:33,394]  - Connection string contains unsupported option 'tlscertificatekeyfile'.
test-backup-restore-atlas | backend stdout |
test-backup-restore-atlas | backend stdout | [2022-11-24 04:55:33,397]  - Cluster created with settings {hosts=[sandbox-mongo.appsmith.com:27017], mode=SINGLE, requiredClusterType=UNKNOWN, serverSelectionTimeout='30000 ms'}
test-backup-restore-atlas | backend stdout |
test-backup-restore-atlas | backend stdout | [2022-11-24 04:55:33,402]  - Connection string contains unsupported option 'tlscertificatekeyfile'.```

Add support to specify the mongoDB client  tlscertificatekeyfile for rts, backend server and the entrypoint script
### Why should this be worked on?

To support TLS/SSL connection on custom MongoDB.

<img src="https://front.com/assets/img/favicons/favicon-32x32.png" height="16" width="16" alt="Front logo" /> [Front conversations](https://app.frontapp.com/open/top_5zkss)
@sum35h sum35h added Enhancement New feature or request Backend This marks the issue or pull request to reference server code Mongo Issues related to Mongo DB plugin DevOps Pod Issues related to devops labels Nov 24, 2022
@github-actions github-actions bot added Integrations Product Issues related to a specific integration and removed DevOps Pod Issues related to devops labels Nov 24, 2022
@sum35h
Copy link
Contributor Author

sum35h commented Nov 24, 2022

FYI, I tweaked the entrypoint.sh with the below line to get it to work.
mongo_state="$(mongo --host mongodb://<usr>:<pwd>@<host>appsmith?authSource=admin --tls --tlsCAFile /appsmith-stacks/rootCA.pem --tlsCertificateKeyFile /appsmith-stacks/mongodb.pem --quiet --eval "rs.status().ok")"

@sum35h sum35h changed the title [Feature]: Support ssl/tls on custom mongoDB [Feature]: Support for MongoDB tlsCertificateKeyFile for clients rts, backend server, entrypoint.sh Nov 25, 2022
@santanu-tft
Copy link

santanu-tft commented May 9, 2023

ok

@Nikhil-Nandagopal Nikhil-Nandagopal added the Query & JS Pod Issues related to the query & JS Pod label Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backend This marks the issue or pull request to reference server code Enhancement New feature or request Integrations Product Issues related to a specific integration Mongo Issues related to Mongo DB plugin Query & JS Pod Issues related to the query & JS Pod
Projects
No open projects
Status: 🥶 Icebox
Development

No branches or pull requests

4 participants