Skip to content

Commit

Permalink
Fix for multi line KUBELET_ARGS
Browse files Browse the repository at this point in the history
  • Loading branch information
bskiba committed Mar 22, 2018
1 parent e8aeb60 commit 060c122
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cluster-autoscaler/cloudprovider/gce/templates.go
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,8 @@ func extractAutoscalerVarFromKubeEnv(kubeEnv, name string) ([]string, error) {
func extractFromKubeEnv(kubeEnv, resource string) ([]string, error) {
result := make([]string, 0)

kubeEnv = strings.Replace(kubeEnv, "\n ", " ", -1)

for line, env := range strings.Split(kubeEnv, "\n") {
env = strings.Trim(env, " ")
if len(env) == 0 {
Expand Down

0 comments on commit 060c122

Please sign in to comment.