| | |
| | | force_basic_auth: yes |
| | | body: "" |
| | | |
| | | ## Enable logging on the cluster |
| | | - name: Create OpenShift Objects for logging |
| | | ignore_errors: yes |
| | | retries: 5 |
| | | delay: 10 |
| | | until: r_objects is succeeded |
| | | register: r_objects |
| | | k8s: |
| | | state: present |
| | | merge_type: |
| | | - strategic-merge |
| | | - merge |
| | | definition: "{{ lookup('file', item ) | from_yaml }}" |
| | | loop: |
| | | - ./files/eo-namespace.yml |
| | | - ./files/clo-namespace.yml |
| | | - ./files/eo-og.yml |
| | | - ./files/eo-sub.yml |
| | | - ./files/eo-role.yml |
| | | - ./files/eo-rb.yml |
| | | # - ./files/clo-og.yml |
| | | # - ./files/clo-sub.yml |
| | | |
| | | - name: Wait for Elasticsearch CRD |
| | | k8s_facts: |
| | | api_version: apiextensions.k8s.io/v1beta1 |
| | | kind: CustomResourceDefinition |
| | | name: elasticsearches.logging.openshift.io |
| | | register: r_elasticsearch_crd |
| | | retries: 20 |
| | | delay: 10 |
| | | ignore_errors: yes |
| | | until: r_elasticsearch_crd.resources | list | length == 1 |
| | | |
| | | - name: Notify user if Elasticsearch deployment failed |
| | | when: not r_elasticsearch_crd.resources | list | length == 1 |
| | | debug: |
| | | msg: "user.info: *** Elasticsearch operator could not be installed ***" |
| | | |
| | | # Leave this as the last task in the playbook. |
| | | - name: workload tasks complete |
| | | debug: |