Forum: Cfengine Help Subject: Re: Advice on using package promises Author: jgreer Link to topic: https://cfengine.com/forum/read.php?3,22672,22690#msg-22690
That results in syntax errors in r2498. It appears not to respect 'package_version' as an alternative to passing the version as part of the promiser and drawing it out with 'package_version_regex'? The error is misleading, too - as though this is the error that should correspond to a missing 'package_list_version_regex' definition. bundle agent packagesClient { packages: "wireshark-1.0.15" package_policy => "addupdate", package_method => yum_rpm_exact, package_select => "==", action => actionsettings_fix_inform("inform"); } body package_method yum_rpm_exact { package_changes => "individual"; package_list_command => "/bin/rpm -qa --qf '%{name} %{version} %{arch}\n'"; package_list_name_regex => "^(\S+?)\s\S+?\s\S+$"; package_list_version_regex => "^\S+?\s(\S+?)\s\S+$"; package_list_arch_regex => "^\S+?\s\S+?\s(\S+)$"; package_list_update_ifelapsed => "1"; package_installed_regex => ".*"; package_name_convention => "$(name)-$(version)"; package_name_regex => ".*"; package_add_command => "/usr/bin/yum -y install"; package_update_command => "/usr/bin/yum -y update"; package_delete_command => "/bin/rpm -e --allmatches"; package_verify_command => "/bin/rpm -V"; } # cf-agent -K !! You must supply a method for determining the version of existing packages I: Made in version 'not specified' of '/var/cfengine/inputs/dcsunix/packagesClient.cf' near line 41 !! You must supply a method for determining the version of existing packages I: Made in version 'not specified' of '/var/cfengine/inputs/dcsunix/packagesClient.cf' near line 41 !! You must supply a method for determining the version of existing packages I: Made in version 'not specified' of '/var/cfengine/inputs/dcsunix/packagesClient.cf' near line 41 _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine