2018-12-23 10:23:31 +01:00
|
|
|
---
|
2019-01-21 18:19:05 +01:00
|
|
|
- name: Prepare private key for backend autodetection test
|
|
|
|
openssl_privatekey:
|
|
|
|
path: '{{ output_dir }}/privatekey_backend_selection.pem'
|
|
|
|
- name: Run module with backend autodetection
|
|
|
|
openssl_csr:
|
|
|
|
path: '{{ output_dir }}/csr_backend_selection.csr'
|
|
|
|
privatekey_path: '{{ output_dir }}/privatekey_backend_selection.pem'
|
|
|
|
subject:
|
|
|
|
commonName: www.ansible.com
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- block:
|
|
|
|
- name: Running tests with pyOpenSSL backend
|
|
|
|
include_tasks: impl.yml
|
|
|
|
vars:
|
|
|
|
select_crypto_backend: pyopenssl
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- import_tasks: ../tests/validate.yml
|
2019-08-23 14:01:42 +02:00
|
|
|
vars:
|
|
|
|
select_crypto_backend: pyopenssl
|
2018-12-23 10:23:31 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
when: pyopenssl_version.stdout is version('0.15', '>=')
|
2017-09-13 23:39:32 +02:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- name: Remove output directory
|
|
|
|
file:
|
|
|
|
path: "{{ output_dir }}"
|
|
|
|
state: absent
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- name: Re-create output directory
|
|
|
|
file:
|
|
|
|
path: "{{ output_dir }}"
|
|
|
|
state: directory
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- block:
|
|
|
|
- name: Running tests with cryptography backend
|
|
|
|
include_tasks: impl.yml
|
|
|
|
vars:
|
|
|
|
select_crypto_backend: cryptography
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
- import_tasks: ../tests/validate.yml
|
2019-08-23 14:01:42 +02:00
|
|
|
vars:
|
|
|
|
select_crypto_backend: pyopenssl
|
2019-01-14 14:33:51 +01:00
|
|
|
|
2019-01-21 18:19:05 +01:00
|
|
|
when: cryptography_version.stdout is version('1.3', '>=')
|