diff options
author | Brenton Leanhardt <bleanhar@redhat.com> | 2016-04-06 10:42:12 -0400 |
---|---|---|
committer | Brenton Leanhardt <bleanhar@redhat.com> | 2016-04-12 14:12:42 -0400 |
commit | 477f04a7a9846579d2bc86d9c260d9849f593961 (patch) | |
tree | 12f5d52295ae92f74843e1a2be83638505563e01 /filter_plugins | |
parent | e284ee1c2dba7f6ceeedf8af4adc60a795721166 (diff) | |
download | openshift-477f04a7a9846579d2bc86d9c260d9849f593961.tar.gz openshift-477f04a7a9846579d2bc86d9c260d9849f593961.tar.bz2 openshift-477f04a7a9846579d2bc86d9c260d9849f593961.tar.xz openshift-477f04a7a9846579d2bc86d9c260d9849f593961.zip |
Containerized installs on RHEL were downgrading docker unnecessarily
Diffstat (limited to 'filter_plugins')
-rw-r--r-- | filter_plugins/oo_filters.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/filter_plugins/oo_filters.py b/filter_plugins/oo_filters.py index 127bd69cf..f6cc2edde 100644 --- a/filter_plugins/oo_filters.py +++ b/filter_plugins/oo_filters.py @@ -791,7 +791,7 @@ class FilterModule(object): return retval @staticmethod - def oo_image_tag_to_rpm_version(version): + def oo_image_tag_to_rpm_version(version, include_dash=False): """ Convert an image tag string to an RPM version if necessary Empty strings and strings that are already in rpm version format are ignored. @@ -802,7 +802,10 @@ class FilterModule(object): raise errors.AnsibleFilterError("|failed expects a string or unicode") if version.startswith("v"): - version = "-" + version.replace("v", "") + version = version.replace("v", "") + + if include_dash: + version = "-" + version return version |