mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 20:24:09 +00:00
commit
a47fe47048
@ -31,14 +31,16 @@ import (
|
|||||||
const APP_VERSION = "0.1"
|
const APP_VERSION = "0.1"
|
||||||
|
|
||||||
// The flag package provides a default help printer via -h switch
|
// The flag package provides a default help printer via -h switch
|
||||||
var versionFlag *bool = flag.Bool("v", false, "Print the version number.")
|
var (
|
||||||
var httpServer *string = flag.String("h", "", "The host to connect to.")
|
versionFlag = flag.Bool("v", false, "Print the version number.")
|
||||||
var config *string = flag.String("c", "", "Path to the config file.")
|
httpServer = flag.String("h", "", "The host to connect to.")
|
||||||
var labelQuery *string = flag.String("l", "", "Label query to use for listing")
|
config = flag.String("c", "", "Path to the config file.")
|
||||||
var updatePeriod *time.Duration = flag.Duration("u", 60*time.Second, "Update interarrival in seconds")
|
labelQuery = flag.String("l", "", "Label query to use for listing")
|
||||||
var portSpec *string = flag.String("p", "", "The port spec, comma-separated list of <external>:<internal>,...")
|
updatePeriod = flag.Duration("u", 60*time.Second, "Update interarrival in seconds")
|
||||||
var servicePort *int = flag.Int("s", -1, "If positive, create and run a corresponding service on this port, only used with 'run'")
|
portSpec = flag.String("p", "", "The port spec, comma-separated list of <external>:<internal>,...")
|
||||||
var authConfig *string = flag.String("auth", os.Getenv("HOME")+"/.kubernetes_auth", "Path to the auth info file. If missing, prompt the user")
|
servicePort = flag.Int("s", -1, "If positive, create and run a corresponding service on this port, only used with 'run'")
|
||||||
|
authConfig = flag.String("auth", os.Getenv("HOME")+"/.kubernetes_auth", "Path to the auth info file. If missing, prompt the user")
|
||||||
|
)
|
||||||
|
|
||||||
func usage() {
|
func usage() {
|
||||||
log.Fatal("Usage: cloudcfg -h <host> [-c config/file.json] [-p <hostPort>:<containerPort>,..., <hostPort-n>:<containerPort-n> <method> <path>")
|
log.Fatal("Usage: cloudcfg -h <host> [-c config/file.json] [-p <hostPort>:<containerPort>,..., <hostPort-n>:<containerPort-n> <method> <path>")
|
||||||
|
Loading…
Reference in New Issue
Block a user