Browse Source

fix #14: wait for the complete deployment of the webhooks and oauth-client pods

master
Nicolas Massé 8 years ago
parent
commit
93fd60a89c
  1. 15
      roles/3scale/tasks/oauth-client.yml
  2. 15
      roles/3scale/tasks/webhooks.yml

15
roles/3scale/tasks/oauth-client.yml

@ -25,6 +25,21 @@
command: oc new-app -n '{{ threescale_project }}' https://github.com/3scale/apicast.git --name=oauth-client --context-dir=/examples/oauth2/client/ -e GATEWAY='https://{{ apicast_hostname }}' command: oc new-app -n '{{ threescale_project }}' https://github.com/3scale/apicast.git --name=oauth-client --context-dir=/examples/oauth2/client/ -e GATEWAY='https://{{ apicast_hostname }}'
when: deploy_needed when: deploy_needed
- name: Wait for OpenShift to create all objects
pause:
seconds: '{{ threescale_delay }}'
when: deploy_needed
- include: common/wait_for.yml
static: no
vars:
pod_to_wait:
- oauth-client
delay: "{{ threescale_delay }}"
retries: "{{ threescale_retries }}"
project: "{{ threescale_project }}"
tags: status
- name: Expose the OAuth client - name: Expose the OAuth client
command: oc expose service oauth-client -n '{{ threescale_project }}' command: oc expose service oauth-client -n '{{ threescale_project }}'
when: deploy_needed when: deploy_needed

15
roles/3scale/tasks/webhooks.yml

@ -13,6 +13,21 @@
command: oc new-app -n '{{ threescale_project }}' https://github.com/nmasse-itix/3scale-webhooks-sample.git --name=webhooks -e SSO_REALM={{ sso_realm }} -e SSO_HOSTNAME={{ sso_route_name }} -e SSO_SERVICE_USERNAME={{ sso_service_username }} -e SSO_SERVICE_PASSWORD={{ sso_service_password }} -e SSO_CLIENT_ID={{ sso_default_client_id }} -e SHARED_SECRET={{ threescale_webhooks_secret }} -e WEBHOOKS_MODULES=log,sso command: oc new-app -n '{{ threescale_project }}' https://github.com/nmasse-itix/3scale-webhooks-sample.git --name=webhooks -e SSO_REALM={{ sso_realm }} -e SSO_HOSTNAME={{ sso_route_name }} -e SSO_SERVICE_USERNAME={{ sso_service_username }} -e SSO_SERVICE_PASSWORD={{ sso_service_password }} -e SSO_CLIENT_ID={{ sso_default_client_id }} -e SHARED_SECRET={{ threescale_webhooks_secret }} -e WEBHOOKS_MODULES=log,sso
when: deploy_needed when: deploy_needed
- name: Wait for OpenShift to create all objects
pause:
seconds: '{{ threescale_delay }}'
when: deploy_needed
- include: common/wait_for.yml
static: no
vars:
pod_to_wait:
- webhooks
delay: "{{ threescale_delay }}"
retries: "{{ threescale_retries }}"
project: "{{ threescale_project }}"
tags: status
- name: Expose the Webhooks service - name: Expose the Webhooks service
command: oc expose service webhooks -n '{{ threescale_project }}' command: oc expose service webhooks -n '{{ threescale_project }}'
when: deploy_needed when: deploy_needed

Loading…
Cancel
Save