kube-forge v2: embede python with ansible (kubespray) and cobra as cli building tool

This commit is contained in:
2025-06-22 00:37:47 +03:00
parent c2df2abc78
commit 4142a9db61
830 changed files with 874 additions and 2047 deletions

21
cmd/upgrade.go Normal file
View File

@@ -0,0 +1,21 @@
package cmd
import (
"kube-forge/internal/kubespray"
"kube-forge/internal/templates"
"github.com/spf13/cobra"
)
func init() {
rootCmd.AddCommand(upgradeCmd)
}
var upgradeCmd = &cobra.Command{
Use: "upgrade",
Short: "Upgrade cluster. Use when changing version of K8s",
Run: func(cmd *cobra.Command, args []string) {
templates.ApplyK8sTemplates()
kubespray.UpgradeCluster("")
},
}