Overview
Run vessl storage --help
to view the list of commands, or vessl storage [COMMAND] --help
to view individual command instructions.
Commands
Create an external storage
vessl storage create [OPTIONS] NAME
Argument | Description |
---|
NAME | Name of the storage |
Option | Description |
---|
--storage-type | (Required) Type of the storage. Options: s3, gcs, nfs, host-path. |
--path | (Required) Path to the storage. The format depends on the storage type: - For
gcs : [bucket_name]/[path] (e.g., my-gcs-bucket) - For
s3 : [bucket_name]/[path] (e.g., my-s3-bucket) - For
nfs : [server]:[path] (e.g., my.nfs.com:/shared/data) - For
host-path : [path] (e.g., /data/host-folder)
|
--credential-name | Credential name registered in vessl credentials. This option is only required when storage type is s3 or gcs |
--cluster-name | Cluster name of registered in vessl. This option is only required when storage type is nfs or host-path |
VESSL External Storage acts as a bridge to external storage services (e.g., S3, GCS, etc.).
Make sure to configure the external storage settings before proceeding.If you do not want to use external storage, you can use the default VESSL storage, vessl-storage
.
Examples
- Create an S3 storage:
vessl storage create --storage-type s3 --path my-s3-bucket --credential-name my-s3-credential my-s3-storage
- Create a GCS(Google Cloud Storage) storage:
vessl storage create --storage-type gcs --path my-gcs-bucket --credential-name my-s3-credential my-gcs-storage
- Create an NFS storage:
vessl storage create --storage-type nfs --path my.nfs.com:/shared/data --cluster-name my-cluster my-nfs-storage
- Create a Host-Path storage:
vessl storage create --storage-type host-path --path /data/host-folder --cluster-name my-cluster my-host-storage
List all storages
Delete an external storage
vessl storage delete NAME
Argument | Description |
---|
NAME | Name of the storage |
Create a volume in storage
vessl storage create-volume [OPTIONS] NAME
Argument | Description |
---|
NAME | Name of the volume |
Option | Description |
---|
--storage-name | (Required) Name of the storage. |
--tag | Tag(s) of the storage. You can attach multiple tags by specifying this option multiple times. |
List volumes in storage
vessl storage list-volumes [OPTIONS]
Option | Description |
---|
--storage-name | (Required) Name of the storage. |
--keyword | Keyword to search for. |
Delete volume in storage
vessl storage delete-volume [OPTIONS] NAME
Argument | Description |
---|
NAME | Name of the volume |
Option | Description |
---|
--storage-name | (Required) Name of the storage. |
Copy a volume file
You can copy a file or directory either from local to a VESSL volume or from a VESSL volume to a local path.
vessl storage copy-file SOURCE DEST
Argument | Description |
---|
SOURCE | Source path. The source can be either a local file path or a VESSL volume. If the source is a VESSL volume, SOURCE must follow the format: volume://{STORAGE_NAME}/{VOLUME_NAME} . |
DEST | Destination path. The destination can be either a local file path or a VESSL volume. If the destination is a VESSL volume, DEST must follow the format: volume://{STORAGE_NAME}/{VOLUME_NAME} . |
One of the paths (either SOURCE
or DEST
) must be a local path, and the other must be a VESSL volume path.
Examples
- Copy a local file to a VESSL volume:
vessl storage copy-file ./local-file.txt volume://my-storage/my-volume
- Copy a directory from a VESSL volume to a local path:
vessl storage copy-file volume://my-storage/my-volume ./local-directory
List a volume file
vessl storage list-files PATH
Argument | Description |
---|
PATH | VESSL volume path. PATH must follow the format: vessl://{STORAGE_NAME}/{VOLUME_NAME} |
Delete a volume file
vessl storage delete-file PATH
Argument | Description |
---|
PATH | VESSL volume path. PATH must follow the format: vessl://{STORAGE_NAME}/{VOLUME_NAME}/{FILE_PATH} |
Option | Description |
---|
-r , --recursive | Required if target file is a directory |