summaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
authorJose A. Rivera <jarrpa@redhat.com>2017-04-17 17:38:43 -0500
committerJose A. Rivera <jarrpa@redhat.com>2017-05-04 11:32:00 +0200
commitf958058cec4671bf463f25bbf13d3e74e11bb9e7 (patch)
tree251af4e8df173df5688ae8d77d6c1b649a99a724 /roles
parentd9ab521292ac660451d50945f60a7bc51305f182 (diff)
downloadopenshift-f958058cec4671bf463f25bbf13d3e74e11bb9e7.tar.gz
openshift-f958058cec4671bf463f25bbf13d3e74e11bb9e7.tar.bz2
openshift-f958058cec4671bf463f25bbf13d3e74e11bb9e7.tar.xz
openshift-f958058cec4671bf463f25bbf13d3e74e11bb9e7.zip
hosted_registry: Get correct pod selector for GlusterFS storage
Signed-off-by: Jose A. Rivera <jarrpa@redhat.com>
Diffstat (limited to 'roles')
-rw-r--r--roles/openshift_hosted/tasks/registry/storage/glusterfs.yml10
1 files changed, 9 insertions, 1 deletions
diff --git a/roles/openshift_hosted/tasks/registry/storage/glusterfs.yml b/roles/openshift_hosted/tasks/registry/storage/glusterfs.yml
index b18b24266..29c2f46ac 100644
--- a/roles/openshift_hosted/tasks/registry/storage/glusterfs.yml
+++ b/roles/openshift_hosted/tasks/registry/storage/glusterfs.yml
@@ -1,10 +1,18 @@
---
+- name: Get registry DeploymentConfig
+ oc_obj:
+ namespace: "{{ openshift_hosted_registry_namespace }}"
+ state: list
+ kind: dc
+ name: "{{ openshift_hosted_registry_name }}"
+ register: registry_dc
+
- name: Wait for registry pods
oc_obj:
namespace: "{{ openshift_hosted_registry_namespace }}"
state: list
kind: pod
- selector: "{{ openshift_hosted_registry_name }}={{ openshift_hosted_registry_namespace }}"
+ selector: "{% for label, value in registry_dc.results.results[0].spec.selector.iteritems() %}{{ label }}={{ value }}{% if not loop.last %},{% endif %}{% endfor %}"
register: registry_pods
until:
- "registry_pods.results.results[0]['items'] | count > 0"