Closed myii closed 5 years ago
First: find a way to prevent the formula from running before having migrated settings is a great idea!
Second: you're only checking that nginx.common
state is called to prevent this. I'm not sure this is sufficient, because people calling nginx
directly will not be affected. Can we find other way to detect it: maybe with a specific pillar in nginx
or detecting nginx.ng
?
@daks Apologies, the implementation isn't clear because I started editing other lines as well to convert to {%-
. In any case, you'll see that I'm specifically checking for nginx.ng
when someone tries to run nginx
. As for all of the other files, they are the entry points that existed before the change to v1.0.0
, so they will be prevented from being run. Essentially, all bases are covered, except for someone trying to run the old nginx
-- that will now trigger the new states and we can discuss (in a further PR) what to check in the pillar to confirm they are on the old style pillar. In the meantime, this PR will cover most of the potential problems, especially for nginx.ng
. If there's no objection, I believe this should be merged ASAP to protect against unwanted breakages.
looks good to me
Thanks for the review, @n-rodriguez.
And thanks to you as well, @daks. Can either of you merge this please (CC: @n-rodriguez)?
Actually, since it's important and potentially time-critical, I've gone ahead and merged based on the the two approvals. Thanks again to everyone involved in reviewing and discussing these issues.
:tada: This PR is included in version 1.0.4 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:
Thanks everyone, perhaps we can take this and note it down somewhere in the template formula docs? Haven't checked if we have a deprecation section in there yet, but we may want to.
@johnkeates Thanks for the suggestion, I've appended that to the documentation section in the "superlist" issue in the template-formula
(link shown above).
nginx/deprecated.sls
Cross-references:
232 -- states deprecated.
233 -- main discussion about the need for this PR (after the merge).
235 -- warning banner added to
README
.Note: There is one common state before and after:
nginx/init.sls
. For that, I've checked for the presence ofnginx:ng
in the map instead.Note: Implementation based on this PR.