mirror of https://github.com/kubernetes/kops.git
Correct spelling mistakes
Signed-off-by: yuxiaobo <yuxiaobogo@163.com>
This commit is contained in:
parent
b550db283c
commit
3b4cd437ed
|
@ -182,7 +182,7 @@ func (e *LaunchConfiguration) Find(c *fi.Context) (*LaunchConfiguration, error)
|
||||||
actual.SecurityGroups = securityGroups
|
actual.SecurityGroups = securityGroups
|
||||||
|
|
||||||
// @step: get the image is order to find out the root device name as using the index
|
// @step: get the image is order to find out the root device name as using the index
|
||||||
// is not vaiable, under conditions they move
|
// is not variable, under conditions they move
|
||||||
image, err := cloud.ResolveImage(fi.StringValue(e.ImageID))
|
image, err := cloud.ResolveImage(fi.StringValue(e.ImageID))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
|
@ -213,7 +213,7 @@ func (t *LaunchTemplate) Find(c *fi.Context) (*LaunchTemplate, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// @step: get the image is order to find out the root device name as using the index
|
// @step: get the image is order to find out the root device name as using the index
|
||||||
// is not vaiable, under conditions they move
|
// is not variable, under conditions they move
|
||||||
image, err := cloud.ResolveImage(fi.StringValue(t.ImageID))
|
image, err := cloud.ResolveImage(fi.StringValue(t.ImageID))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
|
@ -141,7 +141,7 @@ func (s *Subnet) CheckChanges(a, e, changes *Subnet) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
if a != nil {
|
if a != nil {
|
||||||
// TODO: Do we want to destroy & recreate the subnet when theses immutable fields change?
|
// TODO: Do we want to destroy & recreate the subnet when these immutable fields change?
|
||||||
if changes.VPC != nil {
|
if changes.VPC != nil {
|
||||||
var aID *string
|
var aID *string
|
||||||
if a.VPC != nil {
|
if a.VPC != nil {
|
||||||
|
|
|
@ -125,7 +125,7 @@ func (c *Context) Render(a, e, changes Task) error {
|
||||||
|
|
||||||
switch *lifecycle {
|
switch *lifecycle {
|
||||||
case LifecycleExistsAndValidates:
|
case LifecycleExistsAndValidates:
|
||||||
return fmt.Errorf("Lifecycle set to ExistsAndValidates, but object was not found")
|
return fmt.Errorf("lifecycle set to ExistsAndValidates, but object was not found")
|
||||||
case LifecycleExistsAndWarnIfChanges:
|
case LifecycleExistsAndWarnIfChanges:
|
||||||
return NewExistsAndWarnIfChangesError("Lifecycle set to ExistsAndWarnIfChanges and object was not found.")
|
return NewExistsAndWarnIfChangesError("Lifecycle set to ExistsAndWarnIfChanges and object was not found.")
|
||||||
}
|
}
|
||||||
|
@ -158,7 +158,7 @@ func (c *Context) Render(a, e, changes Task) error {
|
||||||
b.WriteTo(out)
|
b.WriteTo(out)
|
||||||
|
|
||||||
if *lifecycle == LifecycleExistsAndValidates {
|
if *lifecycle == LifecycleExistsAndValidates {
|
||||||
return fmt.Errorf("Lifecycle set to ExistsAndValidates, but object did not match")
|
return fmt.Errorf("lifecycle set to ExistsAndValidates, but object did not match")
|
||||||
} else {
|
} else {
|
||||||
// Warn, but then we continue
|
// Warn, but then we continue
|
||||||
return nil
|
return nil
|
||||||
|
@ -205,7 +205,7 @@ func (c *Context) Render(a, e, changes Task) error {
|
||||||
}
|
}
|
||||||
if match {
|
if match {
|
||||||
if renderer != nil {
|
if renderer != nil {
|
||||||
return fmt.Errorf("Found multiple Render methods that could be invokved on %T", e)
|
return fmt.Errorf("found multiple Render methods that could be involved on %T", e)
|
||||||
}
|
}
|
||||||
renderer = &method
|
renderer = &method
|
||||||
rendererArgs = args
|
rendererArgs = args
|
||||||
|
@ -213,7 +213,7 @@ func (c *Context) Render(a, e, changes Task) error {
|
||||||
|
|
||||||
}
|
}
|
||||||
if renderer == nil {
|
if renderer == nil {
|
||||||
return fmt.Errorf("Could not find Render method on type %T (target %T)", e, c.Target)
|
return fmt.Errorf("could not find Render method on type %T (target %T)", e, c.Target)
|
||||||
}
|
}
|
||||||
rendererArgs = append(rendererArgs, reflect.ValueOf(a))
|
rendererArgs = append(rendererArgs, reflect.ValueOf(a))
|
||||||
rendererArgs = append(rendererArgs, reflect.ValueOf(e))
|
rendererArgs = append(rendererArgs, reflect.ValueOf(e))
|
||||||
|
|
|
@ -38,7 +38,7 @@ const (
|
||||||
FileType_Symlink = "symlink"
|
FileType_Symlink = "symlink"
|
||||||
// FileType_Directory defines a directory
|
// FileType_Directory defines a directory
|
||||||
FileType_Directory = "directory"
|
FileType_Directory = "directory"
|
||||||
// FileType_File is a regualar file
|
// FileType_File is a regular file
|
||||||
FileType_File = "file"
|
FileType_File = "file"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ import (
|
||||||
|
|
||||||
func TestFileDependencies(t *testing.T) {
|
func TestFileDependencies(t *testing.T) {
|
||||||
parentFileName := "/dependedon"
|
parentFileName := "/dependedon"
|
||||||
childFileName := "/dependant"
|
childFileName := "/dependent"
|
||||||
|
|
||||||
grid := []struct {
|
grid := []struct {
|
||||||
parent fi.Task
|
parent fi.Task
|
||||||
|
|
|
@ -33,7 +33,7 @@ func YamlUnmarshal(yamlBytes []byte, dest interface{}) error {
|
||||||
return yaml.Unmarshal(yamlBytes, dest)
|
return yaml.Unmarshal(yamlBytes, dest)
|
||||||
}
|
}
|
||||||
|
|
||||||
// YamlMarshal trys to marshal the input struct into yaml content
|
// YamlMarshal tries to marshal the input struct into yaml content
|
||||||
func YamlMarshal(o interface{}) ([]byte, error) {
|
func YamlMarshal(o interface{}) ([]byte, error) {
|
||||||
return yaml.Marshal(o)
|
return yaml.Marshal(o)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue