blob: 1ac78468af7e9883be14b7da5cd1fe92a922c68d (
plain)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
- name: Configure flannel
hosts: oo_first_master
vars:
etcd_urls: "{{ openshift.master.etcd_urls }}"
roles:
- role: flannel_register
when: openshift.common.use_flannel | bool
- name: Additional master configuration
hosts: oo_first_master
vars:
cockpit_plugins: "{{ osm_cockpit_plugins | default(['cockpit-kubernetes']) }}"
etcd_urls: "{{ openshift.master.etcd_urls }}"
openshift_master_ha: "{{ groups.oo_masters | length > 1 }}"
omc_cluster_hosts: "{{ groups.oo_masters | join(' ')}}"
roles:
- role: openshift_master_cluster
when: openshift_master_ha | bool and openshift.master.cluster_method == "pacemaker"
- role: openshift_examples
when: openshift.common.install_examples | bool
- role: openshift_cluster_metrics
when: openshift.common.use_cluster_metrics | bool
- role: openshift_manageiq
when: openshift.common.use_manageiq | bool
- role: cockpit
when: not openshift.common.is_atomic and ( deployment_type in ['atomic-enterprise','openshift-enterprise'] ) and
(osm_use_cockpit | bool or osm_use_cockpit is undefined )
- role: flannel_register
when: openshift.common.use_flannel | bool
- role: pods
when: openshift.common.deployment_type == 'online'
- role: os_env_extras
when: openshift.common.deployment_type == 'online'
- name: Create persistent volumes and create hosted services
hosts: oo_first_master
vars:
attach_registry_volume: "{{ openshift.hosted.registry.storage.kind != None }}"
deploy_infra: "{{ openshift.master.infra_nodes | default([]) | length > 0 }}"
persistent_volumes: "{{ hostvars[groups.oo_first_master.0] | oo_persistent_volumes(groups) }}"
persistent_volume_claims: "{{ hostvars[groups.oo_first_master.0] | oo_persistent_volume_claims }}"
roles:
- role: openshift_persistent_volumes
when: persistent_volumes | length > 0 or persistent_volume_claims | length > 0
- role: openshift_serviceaccounts
openshift_serviceaccounts_names:
- router
- registry
openshift_serviceaccounts_namespace: default
openshift_serviceaccounts_sccs:
- privileged
- role: openshift_router
when: deploy_infra | bool
- role: openshift_registry
registry_volume_claim: "{{ openshift.hosted.registry.storage.volume.name }}-claim"
when: deploy_infra | bool and attach_registry_volume | bool
|