Skip to content
This repository has been archived by the owner on Mar 8, 2022. It is now read-only.

404 Errors when updating auth0_email_template #104

Closed
kevinohara80 opened this issue May 21, 2019 · 3 comments · Fixed by #144
Closed

404 Errors when updating auth0_email_template #104

kevinohara80 opened this issue May 21, 2019 · 3 comments · Fixed by #144
Labels
bug Something isn't working preserve

Comments

@kevinohara80
Copy link

kevinohara80 commented May 21, 2019

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version

v0.11.13

Affected Resource(s)

  • auth0_email_template

Terraform Configuration Files

provider "auth0" {
  domain        = "${var.auth0_domain}"
  client_id     = "${var.auth0_client_id}"
  client_secret = "${var.auth0_client_secret}"
  version       = "~> 0.1.18"
}

variable "auth0_from_email_address" {
  type = "string"
}

resource "auth0_email_template" "verify_email" {
  template                = "verify_email"
  body                    = "${file("./build/verify_email.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Please verify your email address"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 432000
  enabled                 = true
}

resource "auth0_email_template" "welcome_email" {
  template                = "welcome_email"
  body                    = "${file("./build/welcome_email.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Welcome to New Company!"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 0
  enabled                 = true
}

resource "auth0_email_template" "blocked_account" {
  template                = "blocked_account"
  body                    = "${file("./build/blocked_account.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Your New Company account has been blocked"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 432000
  enabled                 = true
}

resource "auth0_email_template" "stolen_credentials" {
  template                = "stolen_credentials"
  body                    = "${file("./build/stolen_credentials.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Your account credentials have been stolen"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 0
  enabled                 = true
}

resource "auth0_email_template" "enrollment_email" {
  template                = "enrollment_email"
  body                    = "${file("./build/enrollment_email.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Enroll in New Company MFA"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 0
  enabled                 = true
}

resource "auth0_email_template" "reset_email" {
  template                = "reset_email"
  body                    = "${file("./build/reset_email.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Change your New Company password"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 432000
  enabled                 = true
}

resource "auth0_email_template" "mfa_oob_code" {
  template                = "mfa_oob_code"
  body                    = "${file("./build/mfa_oob_code.html")}"
  from                    = "${var.auth0_from_email_address}"
  subject                 = "Your New Company MFA code"
  result_url              = ""
  syntax                  = "liquid"
  url_lifetime_in_seconds = 0
  enabled                 = true
}

Debug Output

Gist containing the output of tf plan (which succeeds) and tf apply (which fails)
https://gist.github.com/kevinohara80/a717f67f3c49ba2ffbb2da9b53bc24ed

Expected Behavior

auth0_email_template resource should update upon running terraform apply.

Actual Behavior

auth0_email_template resource are able to be created when running terraform apply for the first time. One the second tf apply, 404 error messages are returned.

Steps to Reproduce

  1. terraform apply to create the initial email template
  2. Make a change to the resource. Example: change the subject
  3. Run terraform apply again to attempt to update
@gtirloni
Copy link

gtirloni commented Aug 6, 2019

Having the same issue with Terraform 0.12.6 and auth0 provider 0.2.0

laurentdutheil pushed a commit to laurentdutheil/terraform-provider-auth0 that referenced this issue Aug 27, 2019
@github-actions
Copy link

This issue is stale because it has been open 30 days with no activity.
Stale issues will be closed after 5 days if no action is taken. If you
think this issue should not be closed, remove the stale label.

@github-actions github-actions bot added the stale label Dec 11, 2019
@alexkappa alexkappa added triage and removed stale labels Dec 11, 2019
@alexkappa
Copy link
Owner

Apologies for the noise. I was trying to cleanup / prioritize. As I have some time on my hands, I will look into the issue soon.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working preserve
Projects
None yet
3 participants