Mounts

Mounts allow users to define mount points for the external data required by an AI Workbench project.

In addition to the target path within the container for each mount, users can also pass a comma separated list of mount options. Each mount target must be an absolute path (i.e. beginning with a ‘/’ character) and unique within the container.

If a new Mount is created while the project container is running, you must restart the project container for the changes to take effect.

Note

A Mount may not be deleted while the project container is running

There are four types of mounts that may be defined: Project, Host, Volume, Temp

Project

This mount type defines where the project repository directory will be mounted within the project container. When an AI Workbench project is created, a Project mount type is added by default with /project/ as the target path within the container for the project directory. There can only be a single Project mount type in a project.

Host

This mount type allows the user to mount a directory from the host machine into the project container.

Volume

This mount type creates a persistent volume for storing data that will not be erased when the project container is stopped or re-built. However, deleting the mount or project will result in the persistent volume being deleted as well. For named volumt mounts, the volume name should be passed as a mount option as volumeName=abc

Temp

This mount type creates a temporary file in the project container that is reset every time the container is started.

Creating a Mount

  • Open AI Workbench window and select the location

  • Select an existing project

  • Select the Environment tab on the left

  • Navigate to the Mounts section and click on the Add button

  • Fill out the form and click on the Add button to create the mount

Deleting a Mount

  • Open AI Workbench window and select the location

  • Select an existing project

  • Select the Environment tab on the left

  • Navigate to the Mounts section and click on the 3 dots and select Remove Host/Volume/Temp Mount

  • Click on Remove to delete the mount

Note

Creating a mount through the CLI only creates the definition for it. Mounts have to be configured by running nvwb configure mounts before they can be used.

Creating a Mount

  • Open the terminal and activate the desired context (location)

  • Run nvwb open to open an existing project

  • Run nvwb create mount

  • Select the mount type

  • Enter the target directory for the mount

  • Enter an optional description

  • Enter mount options, if any

  • Run nvwb configure mounts. Select the mount to configure. Enter the mount source for Host type mount.

Deleting a Mount

  • Open the terminal and activate the desired context (location)

  • Run nvwb open to open an existing project

  • Run nvwb delete mount

  • Select the mount to delete. User will not be prompted for confirmation

There are some differences between how Host mounts are treated by Podman and Docker across macOS, Windows, and Linux. To ensure your Host mounts always work as expected, always make sure the target directory exists in the Project container prior to creating the Host mount.

The easiest way to do this is to use the postInstall.bash script and add something like:

Copy
Copied!
            

sudo mkdir -p /mnt/my-host-mount sudo chmod workbench:workbench /mnt/my-host-mount

If you are using a container that uses a different user than workbench you may need to adjust this command.

In the future AI Workbench will simplify this process.

Previous Secrets (Sensitive Environment Variables)
Next Hardware
© Copyright © 2024, NVIDIA Corporation. Last updated on Apr 29, 2024.