mirror of
https://github.com/ansible-collections/community.crypto.git
synced 2026-05-08 22:33:53 +00:00
Add ansible-lint to CI (#886)
* Enable ansible-lint. * Fix broken task name. * Fix command-instead-of-shell instances. * Clean up tasks to eliminate command-instead-of-module. * Skip yaml errors. * Remove .stdout from versions. * Avoid stdin.
This commit is contained in:
@@ -64,17 +64,17 @@
|
||||
register: generate_csr_changed_check
|
||||
|
||||
- name: "({{ select_crypto_backend }}) Validate CSR (test - privatekey modulus)"
|
||||
shell: '{{ openssl_binary }} rsa -noout -modulus -in {{ remote_tmp_dir }}/privatekey.pem'
|
||||
command: '{{ openssl_binary }} rsa -noout -modulus -in {{ remote_tmp_dir }}/privatekey.pem'
|
||||
register: privatekey_modulus
|
||||
|
||||
- name: "({{ select_crypto_backend }}) Validate CSR (test - Common Name)"
|
||||
shell: "{{ openssl_binary }} req -noout -subject -in /dev/stdin -nameopt oneline,-space_eq"
|
||||
command: "{{ openssl_binary }} req -noout -subject -in /dev/stdin -nameopt oneline,-space_eq"
|
||||
args:
|
||||
stdin: "{{ generate_csr.csr }}"
|
||||
register: csr_cn
|
||||
|
||||
- name: "({{ select_crypto_backend }}) Validate CSR (test - csr modulus)"
|
||||
shell: '{{ openssl_binary }} req -noout -modulus -in /dev/stdin'
|
||||
command: '{{ openssl_binary }} req -noout -modulus -in /dev/stdin'
|
||||
args:
|
||||
stdin: "{{ generate_csr.csr }}"
|
||||
register: csr_modulus
|
||||
|
||||
@@ -24,4 +24,4 @@
|
||||
vars:
|
||||
select_crypto_backend: cryptography
|
||||
|
||||
when: cryptography_version.stdout is version('3.3', '>=')
|
||||
when: cryptography_version is version('3.3', '>=')
|
||||
|
||||
Reference in New Issue
Block a user