Skip to content

Commit

Permalink
use distribution_major_version instead of distribution_version
Browse files Browse the repository at this point in the history
  • Loading branch information
rndmh3ro authored Jul 1, 2019
1 parent 2037ae3 commit 61ec2ff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tasks/pam.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,14 @@
yum:
name: '{{ os_packages_pam_cracklib }}'
state: 'absent'
when: (ansible_facts.os_family == 'RedHat' and ansible_facts.distribution_version|int is version('7', '<') and not ansible_facts.distribution == 'Amazon')
when: (ansible_facts.os_family == 'RedHat' and ansible_facts.distribution_major_version|int is version('7', '<') and not ansible_facts.distribution == 'Amazon')
and os_auth_pam_passwdqc_enable

- name: install the package for strong password checking
yum:
name: '{{ os_packages_pam_passwdqc }}'
state: 'present'
when: (ansible_facts.os_family == 'RedHat' and ansible_facts.distribution_version|int is version('7', '<') and not ansible_facts.distribution == 'Amazon')
when: (ansible_facts.os_family == 'RedHat' and ansible_facts.distribution_major_version|int is version('7', '<') and not ansible_facts.distribution == 'Amazon')
and os_auth_pam_passwdqc_enable

- name: remove passwdqc
Expand Down

0 comments on commit 61ec2ff

Please sign in to comment.