mirror of https://github.com/k3s-io/k3s
commit
4b8ecd68f3
|
@ -54,7 +54,7 @@ type bootstrapTokenData interface {
|
||||||
Tokens() []string
|
Tokens() []string
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewBootstrapTokenPhase returns the phase to boostrapToken
|
// NewBootstrapTokenPhase returns the phase to bootstrapToken
|
||||||
func NewBootstrapTokenPhase() workflow.Phase {
|
func NewBootstrapTokenPhase() workflow.Phase {
|
||||||
return workflow.Phase{
|
return workflow.Phase{
|
||||||
Name: "bootstrap-token",
|
Name: "bootstrap-token",
|
||||||
|
@ -67,11 +67,11 @@ func NewBootstrapTokenPhase() workflow.Phase {
|
||||||
options.KubeconfigPath,
|
options.KubeconfigPath,
|
||||||
options.SkipTokenPrint,
|
options.SkipTokenPrint,
|
||||||
},
|
},
|
||||||
Run: runBoostrapToken,
|
Run: runBootstrapToken,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func runBoostrapToken(c workflow.RunData) error {
|
func runBootstrapToken(c workflow.RunData) error {
|
||||||
data, ok := c.(bootstrapTokenData)
|
data, ok := c.(bootstrapTokenData)
|
||||||
if !ok {
|
if !ok {
|
||||||
return errors.New("bootstrap-token phase invoked with an invalid data struct")
|
return errors.New("bootstrap-token phase invoked with an invalid data struct")
|
||||||
|
|
Loading…
Reference in New Issue