Skip to content

Commit 7e799de

Browse files
committed
[FIX #337] support terraform plan -refresh=false
1 parent 90451d6 commit 7e799de

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

image/actions.sh

+6
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,12 @@ function set-common-plan-args() {
357357
PLAN_ARGS="$PLAN_ARGS -destroy"
358358
fi
359359
fi
360+
361+
if [[ -v INPUT_REFRESH ]]; then
362+
if [[ "$INPUT_REFRESH" == "false" ]]; then
363+
PLAN_ARGS="$PLAN_ARGS -refresh=false"
364+
fi
365+
fi
360366
}
361367

362368
function set-variable-args() {

terraform-plan/action.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@ inputs:
8282
description: Limit the number of concurrent operations
8383
required: false
8484
default: "0"
85+
refresh:
86+
description: Skip checking for external changes to remote objects while creating the plan
87+
required: false
88+
default: "true"
8589

8690
outputs:
8791
changes:

tofu-plan/action.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@ inputs:
8282
description: Limit the number of concurrent operations
8383
required: false
8484
default: "0"
85+
refresh:
86+
description: Skip checking for external changes to remote objects while creating the plan
87+
required: false
88+
default: "true"
8589

8690
outputs:
8791
changes:

0 commit comments

Comments
 (0)