summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOpenShift Bot <eparis+openshiftbot@redhat.com>2017-09-06 22:08:17 -0400
committerGitHub <noreply@github.com>2017-09-06 22:08:17 -0400
commitb2dfd210e56e827108dd3d80a24b2c8631496539 (patch)
treea08dd4586517b133975b38121b01e40078dff501
parente7320ee23086355aa45bcf4229008063d9bc5136 (diff)
parent6e9523431f2dcbc4ea69afbfa1a1f6a4aa65bcef (diff)
downloadopenshift-b2dfd210e56e827108dd3d80a24b2c8631496539.tar.gz
openshift-b2dfd210e56e827108dd3d80a24b2c8631496539.tar.bz2
openshift-b2dfd210e56e827108dd3d80a24b2c8631496539.tar.xz
openshift-b2dfd210e56e827108dd3d80a24b2c8631496539.zip
Merge pull request #5296 from nak3/skeopeo-command-output
Merged by openshift-bot
-rw-r--r--roles/openshift_health_checker/openshift_checks/docker_image_availability.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/roles/openshift_health_checker/openshift_checks/docker_image_availability.py b/roles/openshift_health_checker/openshift_checks/docker_image_availability.py
index 857a80c74..866c74d7c 100644
--- a/roles/openshift_health_checker/openshift_checks/docker_image_availability.py
+++ b/roles/openshift_health_checker/openshift_checks/docker_image_availability.py
@@ -32,6 +32,7 @@ class DockerImageAvailability(DockerHostMixin, OpenShiftCheck):
# we use python-docker-py to check local docker for images, and skopeo
# to look for images available remotely without waiting to pull them.
dependencies = ["python-docker-py", "skopeo"]
+ skopeo_img_check_command = "timeout 10 skopeo inspect --tls-verify=false"
def is_active(self):
"""Skip hosts with unsupported deployment types."""
@@ -67,8 +68,10 @@ class DockerImageAvailability(DockerHostMixin, OpenShiftCheck):
"failed": True,
"msg": (
"One or more required Docker images are not available:\n {}\n"
- "Configured registries: {}"
- ).format(",\n ".join(sorted(unavailable_images)), ", ".join(registries)),
+ "Configured registries: {}\n"
+ "Checked by: {}"
+ ).format(",\n ".join(sorted(unavailable_images)), ", ".join(registries),
+ self.skopeo_img_check_command),
}
return {}
@@ -169,8 +172,7 @@ class DockerImageAvailability(DockerHostMixin, OpenShiftCheck):
for registry in registries:
args = {
- "_raw_params": "timeout 10 skopeo inspect --tls-verify=false "
- "docker://{}/{}".format(registry, image)
+ "_raw_params": self.skopeo_img_check_command + " docker://{}/{}".format(registry, image)
}
result = self.execute_module("command", args)
if result.get("rc", 0) == 0 and not result.get("failed"):