Salt-SSH: pkg module on RH based systems dependent on yum-utils. Need to remove that dependency
Using 2014.7.0rc6
Tested on CentOS 6.5 (ssh-minion on Rackspace)
Probably not describing/wording this entirely accurately. Contact me for other details if needed.
In talking with Tom, we can add this to the Known Issues list of 2014.7.0 and fix in 2014.7.1.
Ran the following command from master: salt-ssh gwtest state.sls apache
Here is the apache.sls:
apache:
pkg.installed:
{% if grains['os_family'] == 'RedHat' %}
- name: httpd
{% elif grains['os_family'] == 'Debian' %}
- name: apache2
{% endif %}
Get the following results on master:
gwtest:
----------
ID: apache
Function: pkg.installed
Name: httpd
Result: False
Comment: The following package(s) were not found, and no possible matches were found in the package db: httpd
Started: 23:49:35.606090
Duration: 51.497 ms
Changes:
Summary
------------
Succeeded: 0
Failed: 1
------------
Total states run: 1
When troubleshooting on ssh-minion, ran this command: python salt-call --local -l debug -c /tmp/.root_1ec649__salt/ pkg.list_pkgs
Get this error:
[ERROR ] Command 'repoquery --plugins --queryformat="%{NAME}_|-%{VERSION}_|-%{RELEASE}_|-%{ARCH}_|-%{REPOID}" --all --pkgnarrow=installed' failed with return code: 127
[ERROR ] stderr: /bin/bash: repoquery: command not found
Installed yum-utils on ssh-minion
Re-ran with success the same command: python salt-call --local -l debug -c /tmp/.root_1ec649__salt/ pkg.list_pkgs
Re-ran state file from master against same minion with a success.
Looks like we have a dependency on yum-utils for this module. Should probably remove this dep.
I added a note about the known issue to the release notes in #16875