forked from openshift/origin
-
Notifications
You must be signed in to change notification settings - Fork 1
/
start.go
35 lines (25 loc) · 960 Bytes
/
start.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package start
import (
"io"
_ "net/http/pprof"
"github.com/spf13/cobra"
"k8s.io/kubernetes/pkg/kubectl/cmd/templates"
"github.com/openshift/origin/pkg/cmd/openshift-etcd"
)
// NewCommandStart provides a CLI handler for 'start' command
func NewCommandStart(basename string, out, errout io.Writer, stopCh <-chan struct{}) *cobra.Command {
cmds := &cobra.Command{
Use: "start",
Short: "Launch OpenShift components",
Long: templates.LongDesc(`
Start components of OpenShift
This command launches components of OpenShift.
`),
Deprecated: "This command will be replaced by the hypershift and hyperkube binaries for starting individual components.",
}
startMaster, _ := NewCommandStartMaster(basename, out, errout)
startEtcdServer, _ := openshift_etcd.NewCommandStartEtcdServer(openshift_etcd.RecommendedStartEtcdServerName, basename, out, errout)
cmds.AddCommand(startMaster)
cmds.AddCommand(startEtcdServer)
return cmds
}