Skip to content

official manual has mistakes in syntax bash  #10119

@ttsrg

Description

@ttsrg

1. What kops version are you running? The command kops version, will display
this information.

Version 1.18.1 (git-453d7d96be)

2. What Kubernetes version are you running? kubectl version will print the
version if a cluster is running or provide the Kubernetes version specified as
a kops flag.

v1.19.3
3. What cloud provider are you using?
aws
4. What commands did you run? What is the simplest way to reproduce this issue?
kops create cluster --help and I've run:
export NODE_SIZE=${NODE_SIZE:-m4.large}
export MASTER_SIZE=${MASTER_SIZE:-m4.large}
export ZONES=${ZONES:-"us-east-1d,us-east-1b,us-east-1c"}

export NODE_SIZE=${NODE_SIZE:-m4.large}
echo $NODE_SIZE
m4.large

then I've tried change data:

export NODE_SIZE=${NODE_SIZE:-t3.small}
echo $NODE_SIZE
m4.large

5. What happened after the commands executed?
variables in export have had constant values

6. What did you expect to happen?
I've got variables without redefine values.
I propose to use classic syntax :
export ZONES="us-east-1d,us-east-1b,us-east-1c" instead of the export ZONES=${ZONES:-"us-east-1d,us-east-1b,us-east-1c"}

and change information in official docs about non-use such construction.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions