Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Permanent diff in pagerduty_service #933

Open
VenelinMartinov opened this issue Oct 1, 2024 · 0 comments
Open

Permanent diff in pagerduty_service #933

VenelinMartinov opened this issue Oct 1, 2024 · 0 comments

Comments

@VenelinMartinov
Copy link

Hi there,

Thank you for opening an issue. Please note that we try to keep the Terraform issue tracker reserved for bug reports and feature requests. For general usage questions, please see: https://www.terraform.io/community.html.

Terraform Version

Run terraform -v to show the version. If you are not running the latest version of Terraform, please upgrade because your issue may have already been fixed.
Terraform v1.9.6

Affected Resource(s)

Please list the resources as a list, for example:

  • pagerduty_service

If this issue appears to affect multiple resources, it may be an issue with Terraform's core, so please mention this.

Terraform Configuration Files

terraform {
  required_providers {
    pagerduty = {
      source  = "pagerduty/pagerduty"
      version = ">= 2.2.1"
    }
  }
}

resource "pagerduty_user" "test_user" {
    name  = "Earline Greenholt"
    email = "<EMAIL>"
}

resource "pagerduty_escalation_policy" "escalate_via_email" {
    name     = "Engineering Escalation Policy"
    num_loops = 2

    rule {
        escalation_delay_in_minutes = 10

        target {
            type = "user_reference"
            id   = pagerduty_user.test_user.id
        }
    }
}

resource "pagerduty_service" "dummy_service" {
    name        = "MyDummy"
    description = "PagerDuty service for My Dummy service"
    
    escalation_policy = pagerduty_escalation_policy.escalate_via_email.id

    auto_pause_notifications_parameters {
        enabled = true
        timeout = 300
    }

    auto_resolve_timeout = null

    incident_urgency_rule {
        type = "constant"

        during_support_hours {
            type    = "constant"
            urgency = "low"
        }

        outside_support_hours {
            type    = "constant"
            urgency = "low"
        }

        urgency = "low"
    }
}

Debug Output

Please provider a link to a GitHub Gist containing the complete debug output: https://www.terraform.io/docs/internals/debugging.html. Please do NOT paste the debug output in the issue; just paste a link to the Gist.

Panic Output

If Terraform produced a panic, please provide a link to a GitHub Gist containing the output of the crash.log.

Expected Behavior

What should have happened?
Terraform plan with no changes in the code should produce no diff

Actual Behavior

What actually happened?
There is a perpetual diff:

Terraform will perform the following actions:

  # pagerduty_service.dummy_service will be updated in-place
  ~ resource "pagerduty_service" "dummy_service" {
        id                      = "PZETJBI"
        name                    = "MyDummy"
        # (11 unchanged attributes hidden)

      ~ incident_urgency_rule {
            # (2 unchanged attributes hidden)

          + during_support_hours {
              + type    = "constant"
              + urgency = "low"
            }

          + outside_support_hours {
              + type    = "constant"
              + urgency = "low"
            }
        }

        # (1 unchanged block hidden)
    }

Plan: 0 to add, 1 to change, 0 to destroy.

Steps to Reproduce

Please list the steps required to reproduce the issue, for example:

  1. terraform apply
  2. terraform plan

Important Factoids

Are there anything atypical about your accounts that we should know? For example: Running in EC2 Classic? Custom version of OpenStack? Tight ACLs?

References

Are there any other GitHub issues (open or closed) or Pull Requests that should be linked here? For example:

  • GH-1234
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

No branches or pull requests

1 participant