Skip to content

docs(iacm): document PLUGIN_ plan flag overrides and TF_CLI_ARGS_plan no-op#11869

Open
dtsong-harness wants to merge 1 commit into
harness:mainfrom
dtsong-harness:docs/iacm-plugin-plan-refresh-flags
Open

docs(iacm): document PLUGIN_ plan flag overrides and TF_CLI_ARGS_plan no-op#11869
dtsong-harness wants to merge 1 commit into
harness:mainfrom
dtsong-harness:docs/iacm-plugin-plan-refresh-flags

Conversation

@dtsong-harness

Copy link
Copy Markdown
Contributor

What was unclear

The IaCM plan step's OpenTofu/Terraform CLI flags (-refresh, -lock, -target, -replace, etc.) are controlled by PLUGIN_ prefixed environment variables, but this was undocumented on the Tofu/Terraform Plugin Commands page. The page already documents TF_CLI_ARGS_fmt as a supported override for the fmt command, which reasonably leads readers to expect the analogous TF_CLI_ARGS_plan to work the same way for plan. It does not: the plan step never reads TF_CLI_ARGS_plan (or any TF_CLI_ARGS_* other than TF_CLI_ARGS_fmt), and silently ignores it rather than erroring.

What this adds

  • A table of the PLUGIN_* environment variables that map to plan CLI flags (PLUGIN_PLAN_REFRESH, PLUGIN_LOCK, PLUGIN_PLAN_TARGET, PLUGIN_PLAN_REPLACE, etc.), with defaults and descriptions.
  • A warning callout stating plainly that TF_CLI_ARGS_plan has no effect on this step, and pointing to the correct PLUGIN_ variable instead.

Evidence

Surfaced from a customer support investigation where TF_CLI_ARGS_plan=-refresh=false was set at the workspace level and silently ignored, and the resulting forced refresh caused a large plan to time out. This is a repeat of an earlier support ticket on the same account; the correct variable (PLUGIN_PLAN_REFRESH) had only ever been shared with the customer via a support ticket comment, never published here. This PR folds that into the public doc so the fix is self-serve.

🤖 Generated with Claude Code

… no-op

The plan step's CLI flags (refresh, lock, target, replace, etc.) are
controlled by PLUGIN_ prefixed environment variables, not the standard
TF_CLI_ARGS_plan convention. This was previously undocumented, leading
customers to set TF_CLI_ARGS_plan expecting it to work like
TF_CLI_ARGS_fmt does for fmt; it is silently ignored instead.
@bot-gitexp-user

Copy link
Copy Markdown

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://6a599830f0bcdf4b33c32a04--harness-developer.netlify.app

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants