mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-12-26 16:09:45 -05:00
c275464634
Upgrade check is used to find updates for the current cluster. Optionally the found upgrades can be persisted to the config for consumption by the upgrade-execute cmd. The old `upgrade execute` in this commit does not work with the new `upgrade plan`. The current versions are read from the cluster. Supported versions are read from the cli and the versionsapi. Adds a new config field MicroserviceVersion that will be used by `upgrade execute` to update the service versions. The field is optional until 2.7 A deprecation warning for the upgrade key is printed during config validation. Kubernetes versions now specify the patch version to make it explicit for users if an upgrade changes the k8s version.
27 lines
549 B
Go
27 lines
549 B
Go
/*
|
|
Copyright (c) Edgeless Systems GmbH
|
|
|
|
SPDX-License-Identifier: AGPL-3.0-only
|
|
*/
|
|
|
|
package cmd
|
|
|
|
import (
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
// NewUpgradeCmd returns a new cobra.Command for the upgrade command.
|
|
func NewUpgradeCmd() *cobra.Command {
|
|
cmd := &cobra.Command{
|
|
Use: "upgrade",
|
|
Short: "Find and execute upgrades to your Constellation cluster",
|
|
Long: "Find and execute upgrades to your Constellation cluster.",
|
|
Args: cobra.ExactArgs(0),
|
|
}
|
|
|
|
cmd.AddCommand(newUpgradeCheckCmd())
|
|
cmd.AddCommand(newUpgradeExecuteCmd())
|
|
|
|
return cmd
|
|
}
|