Exiting a Cloud Workstation Session

There are two mechanisms to exit a Cloud Workstation session - Hold and Shutdown.

Hold and Shut Down sync new content created in the Cloud Workstation back to the Capsule. The main difference between Hold and Shut Down:

  • Hold Keeps all the packages installed and the folder you created in the session. When you return to the session, you can continue working without having to reinstall or recreate them.

  • Shut Down Reminds you of the installed packages, if you want them in your Cloud Workstation, you need to add them to the Capsule environment and rebuild the Capsule first.

Hold and Continue a Cloud Workstation

When exiting a Cloud Workstation via Hold, the system will suspend the docker container from the Capsule. This will preserve all working spaces at the time when you leave the Cloud Workstation. The next time you access the Capsule, it will resume the Cloud Workstation session with all the command history, the files, or folders you created, and the packages you installed in the previous session.

A Cloud Workstation on Hold will not save anything that would be lost when the kernel is shut down. This includes anything in memory (i.e., previously run Jupyter cells, etc.)

For reproducible purposes, it is strongly recommended to install packages using the Environment Editor.

To Exit a Cloud Workstation with Hold

  1. Click the Shut Down button.

  2. Click Hold to return to the Capsule and close the Cloud Workstation.

  3. After the Cloud Workstation is held, the system redirects you to the Capsule view.

    On the Capsule dashboard, you can see the status of the capsule is 'CW on hold' when you hover over the Capsule.

Edit a 'CW on Hold' Capsule

You can edit a Capsule with a 'CW on Hold' status. The Capsule view is the same as the other Capsule. You can add new files, execute a Reproducible Run, attach secret and Data Asset.

You can add packages in the environment editor, but since the Cloud Workstation is on hold (the docker container for the computation is on hold), the changes will be effective when the docker container is rebuilt.

Resume/Discard a 'CW on Hold' Capsule

In the Capsule view under the reproducible run button, you can select Resume or Discard a CW held Capsule.

  • Resume will redirect you to a Cloud Workstation and continue your last session.

  • Discard will shut the Cloud Workstation down.

Collaborating on a Held Capsule

Collaborators can see the Capsule with files synced from a held Cloud Workstation session. If they have edit permissions, they can resume the stopped Cloud Workstation to continue working from the previous session.

To resume the Cloud Workstation, click Resume.

Shut Down a Cloud Workstation

When exiting a Cloud Workstation from Shut Down, the system turns off the docker container associated with the Capsule and syncs back all the content under the "Capsule" folder. This means that it will not preserve any content created outside the "Capsule" folder, or any packages installed during the session. Installed packages will be suggested via a reminder in Package Suggestions, you can choose to add them to the environment editor.

Folders or files saved outside of the ~/capsule directory (which contains /metadata, /environment, /code, /data, /scratch, /results, and other files), or within the/results folder are not synced back to the Capsule and are lost in a new Cloud Workstation session or in the Capsule.

Note: A Cloud Workstation can be shut down, or put on hold either directly from the Cloud Workstation or from the Capsule Dashboard.

Package Suggestions

The system detects new packages that were installed during your Cloud Workstation session. When you shut down the Cloud Workstation and return to the Capsule view, a reminder will appear indicating the new packages that were installed in the Cloud Workstation.

After exiting the Cloud Workstation, the packages installed during the Cloud Workstation session must be reviewed and added to the environment of the Capsule. If you want to reproduce the environment that you created in the Cloud Workstation, go through the package suggestions and add the package to the environment editor. Refer to Package Managers and Adding Packages to learn more about installing packages in the Capsule view.

Behavior of a Capsule Upon Cloud Workstation Hold/Pause and Shutdown

A Cloud Workstation session will be paused when it has run idle (<2% CPU usage) for 2 hours and the browser tab is inactive. Scenarios that will result in an inactive browser tab include: closing the tab, shutting down the browser, and shutting down the computer. Note that a computer’s sleep state doesn’t always result in an inactive browser tab as networking is still taking place. A Cloud Workstation session will continue running if the browser tab is active, even if it has run idle for over 2 hours.