Files
iris-context/commands/sys/rancher.go
T
VERSE 2ef3c90819 feat(commands): more commands (#30)
- I wrote a scripts to copy and generate all commands missing in iris
from fig repo: https://github.com/withfig/autocomplete
- Add a new script to generate commands docs about which commands
currently are inside commands folder
377d4aac663590e504fe39a92eb4dac4cbd333b2
- Add more icons e64d4e70a1db61e62053460a882e093bd6373ab1
2026-07-04 22:08:36 +07:00

79 lines
4.7 KiB
Go

package sys
import (
"github.com/versenilvis/iris/commands/core"
)
func init() {
core.Register(&core.Spec{
Name: "rancher",
Description: "Output format:",
Subcommands: []core.Subcommand{
{Name: "ls", Description: "List all apps in the current Rancher server"},
{Name: "delete", Description: "Delete an app"},
{Name: "APP_NAME/APP_ID", Description: "The name of the app to delete"},
{Name: "install", Description: "Install an app template"},
{Name: "TEMPLATE_NAME/TEMPLATE_PATH", Description: "Install an app template in the current Rancher server"},
{Name: "APP_NAME", Description: "The name of the app to install"},
{Name: "rollback", Description: "Rollback an app to a previous version"},
{Name: "REVISION_ID/REVISION_NAME", Description: "The name/id of the revision to rollback"},
{Name: "upgrade", Description: "Upgrade an existing app to a newer version"},
{Name: "list-templates", Description: "List templates available for installation"},
{Name: "show-template", Description: "Show versions available to install for an app template"},
{Name: "show-app", Description: "Show an app's available versions and revisions"},
{Name: "show-notes", Description: "Show contents of apps notes.txt"},
{Name: "catalog", Description: "Operations with catalogs"},
{Name: "add", Description: "Add a catalog"},
{Name: "CATALOG_NAME", Description: "The name of the catalog to add"},
{Name: "CATALOG_URL", Description: "The URL of the catalog to add"},
{Name: "clusters", Description: "Operations on clusters"},
{Name: "context", Description: "Operations for the context"},
{Name: "globaldns", Description: "Operations on global DNS providers and entries"},
{Name: "inspect", Description: "View details of resources"},
{Name: "kubectl", Description: "Run kubectl commands"},
{Name: "login", Description: "Login to a Rancher server"},
{Name: "SERVER_URL", Description: "The server url you want to login to"},
{Name: "BEARER_TOKEN", Description: "The bearer token you want to use"},
{Name: "machines", Description: "Operations on machines"},
{Name: "multiclusterapps", Description: "Operations with multi-cluster apps"},
{Name: "namespaces", Description: "Operations on namespaces"},
{Name: "nodes", Description: "Operations on nodes"},
{Name: "projects", Description: "Operations on projects"},
{Name: "ps", Description: "Show workloads in a project"},
{Name: "server", Description: "Operations for the server"},
{Name: "current", Description: "Display the current server"},
{Name: "SERVER_NAME", Description: "The name of server you want to delete"},
{Name: "switch", Description: "Switch to a new server"},
{Name: "settings", Description: "Show settings for the current server"},
{Name: "get", Description: "Print a setting"},
{Name: "SETTING_NAME", Description: "The name of setting you want to get"},
{Name: "set", Description: "Set the value for a setting"},
{Name: "SETTINGNAME", Description: "The name of setting you want to set"},
{Name: "SETTING_VALUE", Description: "The value of setting you want to set"},
{Name: "ssh", Description: "SSH into a node"},
{Name: "up", Description: "Apply compose config"},
{Name: "wait", Description: "Wait for resources cluster, app, project, multiClusterApp"},
{Name: "token", Description: "Authenticate and generate new kubeconfig token"},
{Name: "help", Description: "Shows a list of commands or help for one command"},
},
Options: []core.Option{
{Name: "--format", Description: "Output format: 'json', 'yaml' or custom format"},
{Name: "--quiet", Description: "Only display IDs or suppress help text"},
{Name: "--help", Description: "Show help"},
{Name: "--answers", Description: "Path to a helm values file"},
{Name: "--namespace", Description: "Namespace to install the app into"},
{Name: "--set", Description: "Set answers for the template, can be used multiple times. Example: --set foo=bar"},
{Name: "--set-string", Description: "Version of the template to use"},
{Name: "--no-prompt", Description: "Rollback an app to a previous version"},
{Name: "--verbose", Description: "Add a catalog"},
{Name: "--branch", Description: "Branch from the url to use (default: 'master')"},
{Name: "--helm-version", Description: "Operations on clusters"},
{Name: "--token", Description: "API Bearer Token to authenticate Rancher CLI to your Rancher server"},
{Name: "--default", Description: "SSH into a node"},
{Name: "--debug", Description: "Debug logging"},
{Name: "--config", Description: "Path to rancher config (default: `$home/.rancher`) [$RANCHER_CONFIG_DIR]"},
{Name: "--version", Description: "Print the version"},
},
})
}