body file control
{
      inputs => { @(services_autorun.found_inputs) };
}

bundle agent autorun
{
  vars:
    services_autorun::
      "bundles" slist => bundlesmatching(".*", "autorun");

      "sorted_bundles"
        slist => sort("bundles", "lex"),
        comment => "Lexicographically sorted bundles for predictable order";

  methods:
    services_autorun::
      "autorun" usebundle => $(sorted_bundles);

  reports:
    DEBUG|DEBUG_autorun|DEBUG_services_autorun::
      "DEBUG $(this.bundle): found bundle $(sorted_bundles) with tag 'autorun'";
}
