Skip to content

Commit 1552d39

Browse files
committed
More defaults
1 parent d8fdbdf commit 1552d39

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

scripts/migration/helmfile.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ helmfile_apply() {
4141
prefix="${1}"
4242
shift
4343

44-
if [[ "${CK8S_DRY_RUN_INSTALL}" == "true" ]]; then
44+
if [[ "${CK8S_DRY_RUN_INSTALL:-"false"}" == "true" ]]; then
4545
log_info "Dry-running on ${*}"
4646
helmfile_diff "${prefix}" "${@}"
4747
return
@@ -70,7 +70,7 @@ helmfile_destroy() {
7070
prefix="${1}"
7171
shift
7272

73-
if [[ "${CK8S_DRY_RUN_INSTALL}" == "true" ]]; then
73+
if [[ "${CK8S_DRY_RUN_INSTALL:-"false"}" == "true" ]]; then
7474
log_info "Dry-run: Destroy on ${*} ${prefix}"
7575
return
7676
fi
@@ -152,7 +152,7 @@ helmfile_upgrade() {
152152
if ! helmfile_apply "${1}" "namespace=${2},name=${3}"; then
153153
log_error "error: failed to upgrade ${1} ${2}/${3}"
154154

155-
if [[ "${CK8S_DRY_RUN_INSTALL}" == "true" ]]; then
155+
if [[ "${CK8S_DRY_RUN_INSTALL:-"false"}" == "true" ]]; then
156156
return 1
157157
fi
158158

scripts/migration/kubectl.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ kubectl_do() {
1111
log_fatal "Second argument must be a kubectl operation, not an option"
1212
fi
1313

14-
if [[ "${CK8S_DRY_RUN_INSTALL}" == "true" ]]; then
14+
if [[ "${CK8S_DRY_RUN_INSTALL:-"false"}" == "true" ]]; then
1515
local command="${2}"
1616
# List of common commands that generally DO NOT support --dry-run=server
1717
case "${command}" in

0 commit comments

Comments
 (0)