Volumes serve as a solution for managing data within TrueFoundry applications, ensuring that essential information remains accessible and persistent throughout the application's lifecycle.
When running applications in TrueFoundry, it's important to understand that the files stored within a container are temporary. This means that if a container crashes or is stopped, any data created or modified within it is lost. This can lead to challenges for more complex applications that rely on consistent data storage. Additionally, in scenarios where multiple containers run together in a single environment, coordinating file sharing can be complex and prone to errors.
Here's where volumes come into play:
- Data Persistence: Volumes allow TrueFoundry applications to overcome the ephemeral nature of on-disk files in containers. By using volumes, your application's data is stored in a way that is independent of the container's lifecycle. This means that even if a container crashes or is restarted, the data stored in volumes remains intact, providing reliability and consistency.
- Shared Resources: In scenarios where multiple containers need to collaborate and share data, volumes provide a seamless solution. Volumes simplify the process of setting up and accessing shared files among different containers, streamlining the way your applications work together and exchange information.
It's important to note that volumes created within a specific workspace in TrueFoundry are intended to be used exclusively by applications deployed within the same workspace. This localized approach ensures that the volume's data is accessible only to the applications that are part of the same environment, enhancing security and organization.
- On the left panel of the TrueFoundry user interface, locate and click on the "Deployments" tab. From here, navigate to the "Volumes" tab located in the top bar.
- Click on the "New Deployment" button, and a form will appear with various deployment options. Click on the "Volumes" button to select job deployment (will be pre-selected)
- In the same form there will be a field "Where would you like to deploy?" option. Click on the "Search Workspace" bar, and select the desired workspace for your deployment
If you don't have any workspace right now, you can create a new workspace by clicking the Create New Workspace link and following along this Documentation or contact your cluster admin in case of some issues
- Once selected click on the "Next Step" button to continue with the deployment
Now, let's dive into the configuration options for your deployment form. Each of these options plays a crucial role in shaping how your job is deployed and executed.
The "Name" field lets you assign a unique identifier to the volume within your workspace.
The "Storage Class" defines the quality of service and provisioning requirements for the volume. Choose an appropriate storage class based on your application's needs.
Some types of Storage Classes may not be shareable between different applications.
To learn more about this you can go to the following [page]
Specify the size of the volume in gigabytes (Gi). This determines the amount of storage available for your data.
Enable this toggle to provide access to a browser-based interface for interacting with the volume's contents.
- Username: Set a username for logging in to the volume browser.
- TFY Secret containing the password for logging in the volume browser: Link to a TFY secret containing the password for the volume browser.
- Endpoint: Configure the endpoint for accessing the volume browser.
Once configured, click "Create" button to initiate the deployment process. Your application will now benefit from persistent and shareable data storage within the volume, enhancing its reliability and capabilities.
Now that all the deployment options are filled, you can proceed by clicking the "Create" button. This will initiate your deployment process. After clicking "Create," your Volume Dashboard will resemble the following:
While your deployment is in progress, you can hover over the spinner icon to check the status of the deployment. After a brief moment, the deployment should become active, and your Volume Dashboard will transform to appear as follows:
Updated about 1 month ago