Yes! With your two windows open do the following on each:
- Connect both VS Code windows to the same host.
- Using one of the windows, open your project.
- Once your project is open, either build the container or reopen in the container.
- (Optional) To verify the current container name, type
- Using your 2nd window, press the remote connections button (bottom left corner).
- Select the option “Attach to Running Container…” and follow through the dialogues to select the container running in the other window (if necessary, check step 4.).
You now have 2 VS Code windows connected to the same container!
For more details, refer to this step in the container management tutorial.
This is assuming that you are using a dev container or an operating system with
tmux installed. Here are quick start steps:
- In your terminal, type and run
- Now run your long running job.
tmux detachto detach from the tmux session.
- Feel free to disconnect from the server (but leave your devcontainer running!)
- Reconnect to the server and reattach to the devcontainer.
- Your job will either be there running or completed!
For more details, refer to this step in the job management tutorial.