Upload Packages
The platform provides a command-line tool violet, which is used to upload packages downloaded from the Marketplace in the Customer Portal to the platform.
violet supports uploading the following types of packages:
- Operator
- Cluster Plugin
- Helm Chart
When the status of a package in Cluster Plugins or OperatorHub is shown as Absent, you need to use this tool to upload the corresponding package.
The upload process of violet mainly includes the following steps:
- Extract and retrieve information from the package
- Push images to the image registry
- Create Artifact and ArtifactVersion resources on the platform
TOC
Download the ToolFor Linux or macOSFor WindowsPrerequisitesUsageCommon ParametersPlatform Connection ParametersImage Registry Parametersviolet showviolet listOptional Flagsviolet verifyOptional Flagsviolet pushOptional FlagsUpload an Operator to Multiple ClustersUpload an Operator to a Standby Global ClusterUpload a Cluster PluginUpload a Helm Chart to the chart repositoryPush all packages at onceDownload the Tool
Log in to the Customer Portal, navigate to the Downloads page, and click CLI Tools. Download the binary that matches your operating system and architecture.
After downloading, install the tool on your server or PC.
For Linux or macOS
For non-root users:
For root users:
For Windows
-
Download the file and rename it to
violet.exe, or use PowerShell to rename it: -
Run the tool in PowerShell.
Note: If the tool path is not added to your environment variables, you must specify the full path when running commands.
Prerequisites
Permission requirements
- You must provide a valid platform user account (username and password).
- The account must have the role property set to
Systemand the role name must beplatform-admin-system.
Note: If the role property of your account is set to
Custom, you cannot use this tool.
Usage
Common Parameters
Several violet commands accept the following parameters. Refer to individual command sections for specific usage.
Platform Connection Parameters
Image Registry Parameters
IPv6 Address Limitation
For --platform-address and --dest-repo parameters:
- If using an IP address (rather than a domain name), IPv6 format is NOT supported
- Only IPv4 addresses or domain names are supported
violet show
Before uploading a package, use the violet show command to preview its details.
violet list
When upgrading the platform, you can list all plugins that have been uploaded to the platform and export the result to a file. The generated file can then be uploaded to Alauda Cloud so that the required plugin packages can be downloaded.
Optional Flags
For platform connection parameters (--platform-address, --platform-username, --platform-password), see Common Parameters.
violet verify
Use the violet verify command to verify the signature of one or more packages before uploading them.
Two verification methods are supported: checksum and GPG.
The package (.tgz) and its corresponding signature file must be located in the same directory.
Example output:
Explanation:
- Verified successfully with GPG — The listed files have been successfully verified using GPG signature files (with
.sigextension). - Verified successfully with checksum — Files verified using checksum files (e.g.,
.sha256) passed the integrity check. - Verification failed — The listed files failed verification due to mismatched or invalid signatures.
- No verification file found — No corresponding
.sig(GPG) or checksum file was found in the directory.
Optional Flags
violet push
The following examples illustrate common usage scenarios.
For platform connection and image registry parameters, see Common Parameters.
Optional Flags
When --dest-repo is specified, either the authentication info of the image registry or --no-auth MUST be provided.
Upload an Operator to Multiple Clusters
- If
--clustersis not specified, the Operator is uploaded to the global cluster by default.
Upload an Operator to a Standby Global Cluster
When using violet to upload packages to a standby cluster:
- The parameter
--dest-repo <VIP addr of standby cluster>MUST be specified - The parameter
--platform-addressMUST be set to the standby cluster's platform access address - Either the authentication info of the standby cluster's image registry or
--no-authparameter MUST be provided
Otherwise, the packages will be uploaded to the image repository of the primary cluster, preventing the standby cluster from installing or upgrading extensions.
Upload a Cluster Plugin
- You do not need to specify the
--clustersparameter when uploading a Cluster Plugin, as the platform will automatically distribute it based on its affinity configuration. If you specify--clusters, the parameter will be ignored.
Upload a Helm Chart to the chart repository
- Helm Charts can only be uploaded to the default
public-chartsrepository provided by the platform.
Push all packages at once
When multiple packages are downloaded from the Marketplace, you can place them in the same directory and upload them all at once:
When the upgrade target is the global cluster , you can omit the --clusters parameter, as it defaults to uploading to the global cluster.
However, when the upgrade target is a workload cluster, you must specify the --clusters <workload_cluster_name> parameter.