auth0/auth0-deploy-cli

Email template `body` path not respected

jraoult opened this issue · 2 comments

Checklist

Describe the problem you'd like to have solved

I have the following reset_email.json:

{
  "template": "reset_email",
  "from": "",
  "subject": "",
  "syntax": "liquid",
  "body": "./reset_email.html.liquid",
  "urlLifetimeInSeconds": 432000,
  "enabled": true
}

with reset_email.html.liquid seating next to it.

Describe the ideal solution

The deploy CLI should be able to import the template using the path set in the body property. Still, instead, it expects a file matching the same name as the json descriptor ones (in my case reset_email) with a .html extension ignoring the body value.

Surely the body property was intended for cases like mine where the template has a different name. I understand the approach of "convention over configuration", but when there is the configuration, I expect it to take over. I also note that's how it works for the code property when importing actions.

Alternatives and current workarounds

N/A

@jraoult Thanks for this feedback, it is certainly reasonable to expect the tool to respect the defined filepath in body. In fact, I'd consider this more of a bug than anything. I don't see why we couldn't begin to honor that path so long as the default path is the same as what's expected currently; this wasn't an intentional decision AFAICT.

Can't provide a timeline on a fix necessarily but I will recategorize this as a bug and keep open to track progress. Thanks again.

A fix for this has been provided in 7.18.0. Please update and advise if you have any further issue. Thanks again for the feedback!