Feature Request: Native Docker Container Tunneling for Database Connections
Hi JetBrains Team,
In our typical development workflow, we often have multiple projects running concurrently. Each project may involve one or more databases managed within Docker containers. When working with these databases through IntelliJ-based IDEs (e.g., PhpStorm in our case), we currently need to manually expose and bind ports for each database container to enable connectivity from the IDE.
This approach introduces port conflict issues when multiple projects attempt to expose the same ports, effectively preventing them from running simultaneously unless we manually adjust the port mappings — a tedious but manageable workaround if all port allocations are well-tracked.
However, we believe there is a more elegant solution that could be integrated directly into IntelliJ: native support for database tunneling via Docker containers. Given that IntelliJ already supports connecting to Docker daemons, it seems feasible to extend this functionality to allow tunneling into containers for database access without requiring manual port exposure.
We envision this working similarly to the existing SSH/SSL configuration tab within the database connection setup. Specifically:
A “Use Docker Tunnel” checkbox in the database connection settings
A Docker daemon selector (reusing the existing Docker integration)
A container selector dropdown to choose the appropriate container to tunnel through
This would streamline development workflows, eliminate port conflict issues, and improve overall developer productivity when working with containerized databases.
We appreciate your consideration and look forward to any feedback.
Best regards,
Rasmus Milesson
请先登录再写评论。
I have created a feature request on our tracker:
DBE-23460 (https://youtrack.jetbrains.com/issue/DBE-23460) Extending SSH connection to docker containers
Thanks Aleksandr! Is this something I could've done myself and would that have been OK to do?