summaryrefslogtreecommitdiffstats
path: root/roles/lib_openshift
diff options
context:
space:
mode:
Diffstat (limited to 'roles/lib_openshift')
-rw-r--r--roles/lib_openshift/library/oc_route.py12
-rw-r--r--roles/lib_openshift/library/oc_sdnvalidator.py4
-rw-r--r--roles/lib_openshift/src/class/oc_route.py12
3 files changed, 10 insertions, 18 deletions
diff --git a/roles/lib_openshift/library/oc_route.py b/roles/lib_openshift/library/oc_route.py
index 741f608a2..21e7e175b 100644
--- a/roles/lib_openshift/library/oc_route.py
+++ b/roles/lib_openshift/library/oc_route.py
@@ -1594,14 +1594,10 @@ class OCRoute(OpenShiftCLI):
def update(self):
'''update the object'''
- # when the host attribute is being updated, we need to delete and recreate
- if self.config.host != self.route.get_host():
- import time
- self.delete()
- time.sleep(3)
- return self.create()
-
- return self._replace_content(self.kind, self.config.name, self.config.data)
+ return self._replace_content(self.kind,
+ self.config.name,
+ self.config.data,
+ force=(self.config.host != self.route.get_host()))
def needs_update(self):
''' verify an update is needed '''
diff --git a/roles/lib_openshift/library/oc_sdnvalidator.py b/roles/lib_openshift/library/oc_sdnvalidator.py
index 770be29d4..795b775f3 100644
--- a/roles/lib_openshift/library/oc_sdnvalidator.py
+++ b/roles/lib_openshift/library/oc_sdnvalidator.py
@@ -1222,8 +1222,8 @@ class Utils(object):
elif value != user_def[key]:
if debug:
print('value should be identical')
- print(value)
print(user_def[key])
+ print(value)
return False
# recurse on a dictionary
@@ -1243,8 +1243,8 @@ class Utils(object):
if api_values != user_values:
if debug:
print("keys are not equal in dict")
- print(api_values)
print(user_values)
+ print(api_values)
return False
result = Utils.check_def_equal(user_def[key], value, skip_keys=skip_keys, debug=debug)
diff --git a/roles/lib_openshift/src/class/oc_route.py b/roles/lib_openshift/src/class/oc_route.py
index 33ffdcb66..3935525f1 100644
--- a/roles/lib_openshift/src/class/oc_route.py
+++ b/roles/lib_openshift/src/class/oc_route.py
@@ -55,14 +55,10 @@ class OCRoute(OpenShiftCLI):
def update(self):
'''update the object'''
- # when the host attribute is being updated, we need to delete and recreate
- if self.config.host != self.route.get_host():
- import time
- self.delete()
- time.sleep(3)
- return self.create()
-
- return self._replace_content(self.kind, self.config.name, self.config.data)
+ return self._replace_content(self.kind,
+ self.config.name,
+ self.config.data,
+ force=(self.config.host != self.route.get_host()))
def needs_update(self):
''' verify an update is needed '''