diff --git a/salt/modules/yumpkg.py b/salt/modules/yumpkg.py index e962b5928d..add1433412 100644 --- a/salt/modules/yumpkg.py +++ b/salt/modules/yumpkg.py @@ -13,7 +13,7 @@ def __virtual__(): # python <= 2.6 dists = 'CentOS Scientific RedHat Fedora' if dists.count(__grains__['os']): - if int(__grains__['release'].split('.')[0]) >= 6: + if int(__grains__['osrelease'].split('.')[0]) >= 6: return 'pkg' else: return False diff --git a/salt/modules/yumpkg5.py b/salt/modules/yumpkg5.py index 7bccde9b90..5ca0e01749 100644 --- a/salt/modules/yumpkg5.py +++ b/salt/modules/yumpkg5.py @@ -8,7 +8,7 @@ def __virtual__(): # We don't need to support pre-yum OSes because they don't support python 2.6 dists = 'CentOS Scientific RedHat Fedora' if dists.count(__grains__['os']): - if int(__grains__['release'].split('.')[0]) == 5: + if int(__grains__['osrelease'].split('.')[0]) == 5: return 'pkg' else: return False