Uploaded image for project: 'CFEngine Community'
  1. CFEngine Community
  2. CFE-3799

services_autorun_bundles alone, causes errors in policy

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: (None)
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.18.1, 3.19.0
    • Component/s: None
    • Labels:
      None
    • Story Points:
      1

      Description

      With def.json:

      {
        "classes": { "services_autorun_bundles": ["any"] },
      }
      

      I get

         error: Unresolved variable '@(services_autorun.inputs)' in input list, cannot parse
         error: Unresolved variable '@(services_autorun.inputs)' in input list, cannot parse
      

      It seems the fix would be easy in promises.cf

          !(services_autorun|services_autorun_inputs|services_autorun_bundles)::
            # If services_autorun is not enabled, then we should not extend inputs
            # automatically.
            "inputs" slist => { };
            "found_inputs" slist => {};
            "bundles" slist => { "services_autorun" }; # run self
      
          services_autorun|services_autorun_inputs|services_autorun_bundles::
            "inputs" slist => { };
            "bundles" slist => { "autorun" }; # run loaded bundles
      

      I will re-test a bit and make a PR.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              craig.comstock Craig Comstock
              Reporter:
              craig.comstock Craig Comstock
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: