File tree Expand file tree Collapse file tree 1 file changed +32
-0
lines changed Expand file tree Collapse file tree 1 file changed +32
-0
lines changed Original file line number Diff line number Diff line change 1
1
---
2
+ # Required for uri module to work with self-signed certificates and for systems to trust
3
+ # the self-signed CA
4
+ - name : Install CA on controllers
5
+ hosts : controllers
6
+ tasks :
7
+ - name : Copy the intermediate CA
8
+ copy :
9
+ src : " {{ kayobe_env_config_path }}/vault/OS-TLS-ROOT.pem"
10
+ dest : " {{ '/etc/pki/ca-trust/source/anchors/OS-TLS-ROOT.crt' if ansible_facts.os_family == 'RedHat' else '/usr/local/share/ca-certificates/OS-TLS-ROOT.crt' }}"
11
+ mode : 0644
12
+ become : true
13
+
14
+ - name : update system CA
15
+ become : true
16
+ shell : " {{ 'update-ca-trust' if ansible_facts.os_family == 'RedHat' else 'update-ca-certificates' }}"
17
+
2
18
- name : Generate backend API certificates
3
19
hosts : controllers
4
20
vars :
5
21
vault_api_addr : " https://{{ kolla_internal_fqdn }}:8200"
6
22
vault_intermediate_ca_name : " OS-TLS-INT"
7
23
tasks :
24
+ - name : Set a fact about the virtualenv on the remote system
25
+ set_fact :
26
+ virtualenv : " {{ ansible_python_interpreter | dirname | dirname }}"
27
+ when :
28
+ - ansible_python_interpreter is defined
29
+ - not ansible_python_interpreter.startswith('/bin/')
30
+ - not ansible_python_interpreter.startswith('/usr/bin/')
31
+
32
+ - name : Ensure Python hvac module is installed
33
+ pip :
34
+ name : hvac
35
+ state : latest
36
+ extra_args : " {% if pip_upper_constraints_file %}-c {{ pip_upper_constraints_file }}{% endif %}"
37
+ virtualenv : " {{ virtualenv is defined | ternary(virtualenv, omit) }}"
38
+ become : " {{ virtualenv is not defined }}"
39
+
8
40
- name : Include Vault keys
9
41
include_vars :
10
42
file : " {{ kayobe_env_config_path }}/vault/overcloud-vault-keys.json"
You can’t perform that action at this time.
0 commit comments