You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 line
889B

  1. ---
  2. # setup ca directory
  3. - name: directory
  4. file:
  5. path: "{{ certificate_authority_directory }}"
  6. state: directory
  7. - name: subdirectories
  8. file:
  9. path: "{{ certificate_authority_directory }}/{{ item }}"
  10. state: directory
  11. with_items:
  12. - certs
  13. - crl
  14. - csr
  15. - cnf
  16. - newcerts
  17. - name: private directory
  18. file:
  19. path: "{{ certificate_authority_directory }}/private"
  20. mode: 0700
  21. state: directory
  22. - name: index
  23. copy:
  24. content: ""
  25. dest: "{{ certificate_authority_directory }}/index"
  26. force: no
  27. - name: index config
  28. template:
  29. src: index.attr.j2
  30. dest: "{{ certificate_authority_directory }}/index.attr"
  31. - name: serial
  32. copy:
  33. content: "00\n"
  34. dest: "{{ certificate_authority_directory }}/serial"
  35. force: no
  36. - name: config
  37. template:
  38. src: ca.cnf.j2
  39. dest: "{{ certificate_authority_directory }}/cnf/ca.cnf"