Re: Re: How to join multiple parts of one data container

"'Nick Anderson' via help-cfengine" <[email protected]> Fri, 28 Jul 2023 10:48:56 -0500
Newsgroups gmane.comp.sysutils.cfengine.general
Message-ID <[email protected]>
        Hi all, I have a solution (thanks to Bas):

        "level1_ubuntu" data => '@(repos[ubuntu_16])';
        "level1_debian" data => '@(repos[debian_12])';
        "level2_list" data => '[ level1_ubuntu[hwraid],
        level1_debian[icinga] ]';

        That works, but there are too many lines. Is there a
        better solution?

  Too many lines?

  You mean level1_<everydistrorelease>, level2_list
  <everylevel1_distro[KEY]>?

  I kind of imagine that getindices() could help but it starts to look
  like a lot of /programming/ in a state oriented DSL. Makes me think
  that it might be a better fit for something else outside CFEngine.
  Perhaps some pre-processing scripts to munge the data into the formats
  you need.

  While you can do some of this in CFEngine, (and I am usually tempted
  to try quite hard because I find it entertaining, and also prize the
  value of not relying on anything external) it can become a yak shaving
  exercise that winds up having a higher maintenance burden.

-- 
You received this message because you are subscribed to the Google Groups "help-cfengine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/help-cfengine/87edksf34n.fsf%40northern.tech.