-
Notifications
You must be signed in to change notification settings - Fork 0
/
ovirt.yml
61 lines (49 loc) · 1.49 KB
/
ovirt.yml
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
57
58
59
60
61
---
- name: oVirt Host
become: true
hosts: ovirt
tasks:
- name: Check correct OS version
assert:
that:
- ("{{ ansible_distribution }} == RedHat") or ("{{ ansible_distribution }} == CentOS")
- "{{ ansible_distribution_major_version }} == 7"
fail_msg: "Incompatible OS version detected"
- name: Install oVirt repos
yum:
name: https://resources.ovirt.org/pub/yum-repo/ovirt-release43.rpm
state: present
- name: Install oVirt cockpit dashboard
yum:
name: cockpit-ovirt-dashboard
state: present
- name: Enable cockpit firewall ports
firewalld:
service: cockpit
immediate: yes
permanent: yes
state: enabled
- name: Enable cockpit
systemd:
name: cockpit.socket
state: started
# Now we need to bootstrap oVirt via cockpit http :-(
- name: Notify user
debug:
msg: "Please login to cockpit at https://{{ ansible_fqdn }}:9090 to complete the oVirt installation"
# yum install ovirt-hosted-engine-setup
# hosted-engine --deploy
###############################################################################
# Add prometheus exporter
# - name: oVirt VDSM Prometheus exporter
# become: true
# hosts: ovirt
# tasks:
# - import_role:
# name: ansible-vdsm-prometheus
# tags:
# - monitoring
# vars:
# vdsm_prom_ca: /etc/ipa/ca.crt
# vdsm_prom_cert: /etc/pki/tls/certs/{{ ansible_fqdn }}.pem
# vdsm_prom_key: /etc/pki/tls/private/{{ ansible_fqdn }}.key