summaryrefslogtreecommitdiffstats
path: root/playbooks/common
diff options
context:
space:
mode:
authorJan Chaloupka <jchaloup@redhat.com>2017-02-09 12:29:45 +0100
committerJan Chaloupka <jchaloup@redhat.com>2017-02-11 20:59:03 +0100
commitc96cbe38a9dfd08909687b347dc00a18a894b235 (patch)
treed8d12efc939a3fcef00f4d784221c3439c9a0959 /playbooks/common
parentfc96d8d22f6c277b599e6e2fa4e9cc06814a9460 (diff)
downloadopenshift-c96cbe38a9dfd08909687b347dc00a18a894b235.tar.gz
openshift-c96cbe38a9dfd08909687b347dc00a18a894b235.tar.bz2
openshift-c96cbe38a9dfd08909687b347dc00a18a894b235.tar.xz
openshift-c96cbe38a9dfd08909687b347dc00a18a894b235.zip
replace 'oc service' command with its lib_openshift equivalent
Diffstat (limited to 'playbooks/common')
-rw-r--r--playbooks/common/openshift-cluster/redeploy-certificates/registry.yml15
1 files changed, 9 insertions, 6 deletions
diff --git a/playbooks/common/openshift-cluster/redeploy-certificates/registry.yml b/playbooks/common/openshift-cluster/redeploy-certificates/registry.yml
index 18b93e1d6..8cf65740c 100644
--- a/playbooks/common/openshift-cluster/redeploy-certificates/registry.yml
+++ b/playbooks/common/openshift-cluster/redeploy-certificates/registry.yml
@@ -46,12 +46,15 @@
# Replace dc/docker-registry certificate secret contents if set.
- block:
+ - name: Load lib_openshift modules
+ include_role:
+ name: lib_openshift
+
- name: Retrieve registry service IP
- command: >
- {{ openshift.common.client_binary }} get service docker-registry
- -o jsonpath='{.spec.clusterIP}'
- --config={{ mktemp.stdout }}/admin.kubeconfig
- -n default
+ oc_service:
+ namespace: default
+ name: docker-registry
+ state: list
register: docker_registry_service_ip
changed_when: false
@@ -65,7 +68,7 @@
--signer-cert={{ openshift.common.config_base }}/master/ca.crt
--signer-key={{ openshift.common.config_base }}/master/ca.key
--signer-serial={{ openshift.common.config_base }}/master/ca.serial.txt
- --hostnames="{{ docker_registry_service_ip.stdout }},docker-registry.default.svc.cluster.local,{{ docker_registry_route_hostname }}"
+ --hostnames="{{ docker_registry_service_ip.results.clusterip }},docker-registry.default.svc.cluster.local,{{ docker_registry_route_hostname }}"
--cert={{ openshift.common.config_base }}/master/registry.crt
--key={{ openshift.common.config_base }}/master/registry.key