Skip to content

terraform apply <planfile> fails, when terraform apply succeeds #21624

@simoncocking

Description

@simoncocking

Terraform Version

Terraform v0.12.1
+ provider.aws v2.13.0
+ provider.external v1.1.2
+ provider.template v2.1.2

Terraform Configuration Files

See this zip file encrypted with your GPG key.

Debug Output

Traces for both terraform plan and terraform apply phases are in the above zip file, as is the generated plan file (which contains our Terraform code).

Expected Behavior

The plan should have been applied without error.

Actual Behavior

Many instances of the following errors:

Error: Resource node has no configuration attached

The graph node for
module.dwh.module.legal_status_table.data.template_file.to_s3 has no
configuration attached to it. This suggests a bug in Terraform's apply graph
builder; please report it!

and

Error: orphan resource module.dwh.module.f_term_info_table.aws_glue_trigger.on_demand still has a non-empty state after apply; this is a bug in Terraform

Steps to Reproduce

  1. terraform init
  2. terraform plan -out=staging.tfplan
  3. terraform apply staging.tfplan

Note that when omitting the plan phase and allowing terraform apply to calculate the plan itself, the apply succeeds without error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions