2015-06-04 01:01:23 +08:00
|
|
|
---
|
2024-02-14 18:14:02 +08:00
|
|
|
- name: Install nss-tools on redhat
|
|
|
|
ansible.builtin.package:
|
2016-10-07 16:36:19 +08:00
|
|
|
name: nss-tools
|
2016-03-03 21:43:01 +08:00
|
|
|
state: present
|
2018-12-19 21:55:01 +08:00
|
|
|
register: result
|
|
|
|
until: result is succeeded
|
2021-03-03 22:43:50 +08:00
|
|
|
when: ansible_facts['pkg_mgr'] == 'yum' or ansible_facts['pkg_mgr'] == 'dnf'
|
2016-03-03 21:43:01 +08:00
|
|
|
|
2024-02-14 18:14:02 +08:00
|
|
|
- name: Install libnss3-tools on debian
|
|
|
|
ansible.builtin.package:
|
2016-03-03 21:43:01 +08:00
|
|
|
name: libnss3-tools
|
|
|
|
state: present
|
2018-12-19 21:55:01 +08:00
|
|
|
register: result
|
|
|
|
until: result is succeeded
|
2021-03-03 22:43:50 +08:00
|
|
|
when: ansible_facts['pkg_mgr'] == 'apt'
|
2016-03-03 21:43:01 +08:00
|
|
|
|
2024-02-14 18:14:02 +08:00
|
|
|
- name: Create nss directory for keystone certificates
|
|
|
|
ansible.builtin.file:
|
2015-10-19 11:19:31 +08:00
|
|
|
path: "{{ radosgw_nss_db_path }}"
|
|
|
|
state: directory
|
|
|
|
owner: root
|
|
|
|
group: root
|
2024-02-14 18:14:02 +08:00
|
|
|
mode: "0644"
|
2015-06-04 01:01:23 +08:00
|
|
|
|
2024-02-14 18:14:02 +08:00
|
|
|
- name: Create nss entries for keystone certificates
|
|
|
|
ansible.builtin.shell: "{{ item }}"
|
2018-10-30 22:51:32 +08:00
|
|
|
changed_when: false
|
2015-06-04 01:01:23 +08:00
|
|
|
with_items:
|
2018-10-30 22:51:32 +08:00
|
|
|
- "openssl x509 -in /etc/keystone/ssl/certs/ca.pem -pubkey | certutil -d {{ radosgw_nss_db_path }} -A -n ca -t 'TCu,Cu,Tuw'"
|
2015-06-04 01:01:23 +08:00
|
|
|
- "openssl x509 -in /etc/keystone/ssl/certs/signing_cert.pem -pubkey | certutil -A -d {{ radosgw_nss_db_path }} -n signing_cert -t 'P,P,P'"
|
2019-04-01 23:46:15 +08:00
|
|
|
tags: skip_ansible_lint
|