Browse Source

Merge pull request #1076 from sdodson/versions

Clean up versions.sh
Thomas Wiest 9 years ago
parent
commit
2200cf224c
1 changed files with 2 additions and 3 deletions
  1. 2 3
      playbooks/common/openshift-cluster/upgrades/files/versions.sh

+ 2 - 3
playbooks/common/openshift-cluster/upgrades/files/versions.sh

@@ -1,9 +1,8 @@
 #!/bin/bash
 
-yum_installed=$(yum list installed "$@" 2>&1 | tail -n +2 | grep -v 'Installed Packages' | grep -v 'Red Hat Subscription Management' | grep -v 'Error:' | awk '{ print $2 }' | tr '\n' ' ')
-
-yum_available=$(yum list available -q "$@" 2>&1 | tail -n +2 | grep -v 'Available Packages' | grep -v 'Red Hat Subscription Management' | grep -v 'el7ose' | grep -v 'Error:' | awk '{ print $2 }' | tr '\n' ' ')
+yum_installed=$(yum list installed -e 0 -q "$@" 2>&1 | tail -n +2 | awk '{ print $2 }' | tr '\n' ' ')
 
+yum_available=$(yum list available -e 0 -q "$@" 2>&1 | tail -n +2 | grep -v 'el7ose' | awk '{ print $2 }' | tr '\n' ' ')
 
 echo "---"
 echo "curr_version: ${yum_installed}"