Fix afs_slug for centos-7

Because, why can't things be the same across distros?  We need
ansible_distribution_major_version for centos (7) and
ansible_distribution_version for ubuntu (16.04).

Change-Id: I06f3b587a78165674d0d09432164d79caa5ecf02
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
Paul Belanger 2017-11-16 19:33:41 -05:00
parent 548c726dbd
commit 251bce14c0
No known key found for this signature in database
GPG Key ID: 611A80832067AF38
1 changed files with 7 additions and 1 deletions

View File

@ -2,9 +2,15 @@
strategy: free
pre_tasks:
- name: Generate AFS slug
- name: Generate AFS slug - CentOS
set_fact:
afs_slug: "{{ ansible_distribution|lower }}-{{ ansible_distribution_major_version }}-{{ ansible_architecture }}"
when: ansible_distribution == "CentOS"
- name: Generate AFS slug - Ubuntu
set_fact:
afs_slug: "{{ ansible_distribution|lower }}-{{ ansible_distribution_version }}-{{ ansible_architecture }}"
when: ansible_distribution == "Ubuntu"
- name: Set fact for AFS dir
set_fact: