-
Notifications
You must be signed in to change notification settings - Fork 73
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
Fixes #7126: Add a new system variable for the \"rudder_directives\" bundle #917
Fixes #7126: Add a new system variable for the \"rudder_directives\" bundle #917
Conversation
SystemVariable(systemVariableSpecService.get("INPUTLIST"), Seq(inputs.distinct.mkString("\"", "\",\"", "\""))) | ||
, SystemVariable(systemVariableSpecService.get("BUNDLELIST"), Seq(bundleSeq.map( _._2.name).mkString(", ", ", ", ""))) | ||
, SystemVariable(systemVariableSpecService.get("RUDDER_DIRECTIVES_SEQUENCE"), | ||
Seq(bundleSeq.map { case (promisee, bundle) => s""" "${promisee} usebundle => ${bundle.name};" """}.mkString( "\n")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be promiser, not promisee. Promisee is a whole different concept in CFEngine. See http://syslog.me/2013/05/21/the-value-of-the-promisee-in-cfengine-promises/.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should indeed be called promiser
Plus, you have invalid quoting, the line should probably be
"${promiser}" usebundle => ${bundle.name};
PR updated |
3aabc5c
to
1d1145a
Compare
// We need to remove zero-length bundle name from the bundlesequence (like, if there is no ncf bundles to call) | ||
// to avoid having two successives commas in the bundlesequence | ||
val techniqueBundles = technique.bundlesequence.flatMap { bundle => | ||
if(bundle.name.trim.size > 0) { | ||
Some(bundle) | ||
Some((technique, promisee, bundle)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should still be promiser
PR updated |
1d1145a
to
c4eb79f
Compare
PR updated |
c4eb79f
to
db0a3dd
Compare
…_for_the_rudder_directives_bundle Fixes #7126: Add a new system variable for the \"rudder_directives\" bundle
https://www.rudder-project.org/redmine/issues/7126