Docker Interactive Terminal?
I have Docker Desktop installed on my Mac. From the Docker Dashboard, I can click the terminal icon of a running container to access an interactive command line for that container. Is there a way to do this from the Docker service in Jetbrains IDE?
The Jetbrains Docker UI provides lots of nice functionality that Docker Desktop does not - including the file browser. However, there are times when I need to access the command line inside the running container. Anyway to do that?
Please sign in to leave a comment.
Go to 'Services' tool window -> Docker -> (service name) -> (container name), right click and click "Exec".
Then run the shell (e.g. `/bin/bash`)
Thanks much! 👍
Is there a keyboard shortcut to move the cursor into this shell? (my intention is to switch between editor and terminal using IdeaVIM) THX
Unfortunately, it is not possible to assign a key shortcut to the specific "Services" tab. You may switch from editor to the whole "Services" window but its last state will be opened then, not necessarily the "Exec" tab.
1. Alt + 8 Open "Services" window
2. Use cursor keys to go to the container (up/down, and right/left to expand, if multiple containers under a given service name)
3. Alt + F10 opens the bash shell for the container
4. Press "Tab" to go to the right-pane (the terminal pane)
Without having to touch the mouse.
These look like a lot of steps, but with some practice (of a few days), this starts to feel very natural and fast.
TL;DR
Alt + 8
Up/Down to select the service/container
Alt + F10
Tab
Right-click Services | Docker there is a Connect option, no Exec.
Alt+F10 does not work for me. Is there another way to open the shell for the container?