xoxys.ucs/tasks/tls.yml

24 lines
640 B
YAML
Raw Normal View History

2018-08-04 20:23:06 +00:00
---
- block:
- name: Create tls folder structure
file:
path: "{{ item }}"
state: directory
mode: 700
with_items:
- "{{ ucs_tls_certs_dir }}"
- "{{ ucs_tls_key_dir }}"
- name: Copy certs and private key
copy:
src: "{{ item.src }}"
dest: "{{ item.dest }}"
mode: "{{item.mode }}"
with_items:
2018-08-04 20:32:11 +00:00
- { src: "{{ ucs_tls_key_path }}", dest: "{{ ucs_tls_certs_dir }}/ucs.pem", mode: '0600' }
- { src: "{{ ucs_tls_cert_path }}", dest: "{{ ucs_tls_key_dir }}/unifi.pem }}", mode: '0750' }
2018-08-04 20:34:33 +00:00
loop_control:
label: "{{ item.dest }}"
2018-08-04 20:23:06 +00:00
become: True
become_user: root