-
Notifications
You must be signed in to change notification settings - Fork 2
/
iotagent-json-send.yaml
42 lines (42 loc) · 1.34 KB
/
iotagent-json-send.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
- name: Install a CRD resource from OpenShift
hosts: localhost
connection: local
gather_facts: false
pre_tasks:
- fail:
msg: Variable crd_path is not defined
when: crd_path is not defined
- name: "Query CRD"
set_fact:
crd_complete: "{{ (lookup('file', crd_path) | from_yaml) }}"
- name: "Set crd var"
set_fact:
crd: "{{ crd_complete.spec }}"
when: crd_path is defined
- name: "Set name var"
set_fact:
ansible_operator_meta_name: "{{ crd_complete.metadata.name }}"
when:
crd_path is defined and ansible_operator_meta_name is not defined
- name: "Set namespace var"
set_fact:
ansible_operator_meta_namespace: "{{ crd_complete.metadata.namespace }}"
when:
crd_path is defined and ansible_operator_meta_namespace is not defined
- name: "Set ENTITY_TYPE var"
set_fact:
ENTITY_TYPE: "{{ crd_complete.kind }}"
roles:
- smart-data-model-vars
- iotagent-json-send
vars:
ansible_operator_meta:
name: "{{ ansible_operator_meta_name }}"
namespace: "{{ ansible_operator_meta_namespace }}"
mqtt_nodeport: 30083
mqtt_nodeport_hostname: mqtt.apps-crc.testing
amqp_nodeport: 30072
amqp_nodeport_hostname: amqp.apps-crc.testing
verify_connections: false
enable_dev_nodeports: false