-
Notifications
You must be signed in to change notification settings - Fork 290
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
Stop using scope.lookupvar() in templates #701
Comments
|
If we move the variables to the classes where they are really used, we will break backward compatibility. To maintain backward compatibility in the first step, I could add the variables to sensu::package and source them in from the main class. This way you get the same results using the old way. class sensu::package (
$log_dir = $::sensu::log_dir,
) { |
|
Let's go the second route and do variable assignment that references variables in the main class. Eventually I'd like to collapse all these extra classes and this will make it easier to understand where the variables come from. |
Add tests for existing functionality as preparation.
|
Working on this in PR #724 |
Add tests for existing functionality as preparation.
Use local variables that reference to main class.
Add tests for existing functionality as preparation.
Use local variables that reference to main class.
Use local variables that reference to main class.
Add tests for existing functionality as proof for backward compatibility.
Add tests for existing functionality as proof for backward compatibility.
(GH-701) Stop using scope.lookupvar() in templates
|
this issue can be closed now :) |
|
Released in v2.22.0 |
We should bring the variables into the local scope and use
@variablehttps://docs.puppet.com/puppet/4.10/lang_template_erb.html#accessing-puppet-variables
The text was updated successfully, but these errors were encountered: