Skip to content

Commit

Permalink
Merge pull request #1 from roles-ansible/os
Browse files Browse the repository at this point in the history
create warning if OS is not supported
  • Loading branch information
DO1JLR authored Mar 2, 2020
2 parents 86f9536 + a4410fa commit 9dec3b7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 18 deletions.
19 changes: 1 addition & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,27 +69,10 @@ This role is tested with [these github-action](https://github.com/search?q=topic
If you want to find out more about our tests, please have a look at the github marketplace.
| test status | Github Marketplace |
| :---------: | :----------------: |
| :--------- | :---------------- |
| [![Travis Build Status](https://travis-ci.org/roles-ansible/role_install-epel-release.svg?branch=master)](https://travis-ci.org/roles-ansible/role_install-epel-release) | [.travis.yml](https://github.com/roles-ansible/role_install-epel-release/blob/master/.travis.yml) |
| [![Ansible check centos:latest](https://github.com/roles-ansible/role_install-epel-release/workflows/Ansible%20check%20centos:latest/badge.svg)](https://github.com/roles-ansible/role_install-epel-release/actions?query=workflow%3A%22Ansible+check+centos%3Alatest%22) | [ansible test with centos:latest](https://github.com/roles-ansible/role_install-epel-release/blob/master/.travis.yml) | [ansible test with centos latest](https://github.com/marketplace/actions/check-ansible-centos-latest) |
| [![Ansible check centos:centos8](https://github.com/roles-ansible/role_install-epel-release/workflows/Ansible%20check%20centos:centos8/badge.svg)](https://github.com/roles-ansible/role_install-epel-release/actions?query=workflow%3A%22Ansible+check+centos%3Acentos8%22) | [ansible test with centos 8](https://github.com/marketplace/actions/check-ansible-centos-centos8) |
| [![Ansible check centos:centos7](https://github.com/roles-ansible/role_install-epel-release/workflows/Ansible%20check%20centos:centos7/badge.svg)](https://github.com/roles-ansible/role_install-epel-release/actions?query=workflow%3A%22Ansible+check+centos%3Acentos7%22) | [ansible test with centos 7](https://github.com/marketplace/actions/check-ansible-centos-centos7) |
| [![Ansible check centos:centos6](https://github.com/roles-ansible/role_install-epel-release/workflows/Ansible%20check%20centos:centos6/badge.svg)](https://github.com/roles-ansible/role_install-epel-release/actions?query=workflow%3A%22Ansible+check+centos%3Acentos6%22) | [ansible test with centos 6](https://github.com/marketplace/actions/check-ansible-centos-centos6) |
| [![Ansible Lint check](https://github.com/roles-ansible/role_install-epel-release/workflows/Ansible%20Lint%20check/badge.svg)](https://github.com/roles-ansible/role_install-epel-release/actions?query=workflow%3A%22Ansible+Lint+check%22) | [ansible linting test](https://github.com/marketplace/actions/ansible-lint) |
WIP
----
```
WORK IN PROGRESS

missing:
- os detection (RHEL)

working:
- docs
- epel install on centos 7
- github-actions
- vars
```
11 changes: 11 additions & 0 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@
state: present
fingerprint: "{{ epel_repo['fingerprint'][ ansible_distribution_major_version ] }}"
become: true
when:
- ansible_os_family == 'RedHat'
- ansible_distribution != 'Fedorra'

- name: Install EPEL repo
become: true
Expand All @@ -29,3 +32,11 @@
register: result
until: result is succeeded
retries: 3
when:
- ansible_os_family == 'RedHat'
- ansible_distribution != 'Fedorra'

- name: info for fedora and non RHEL
pause:
prompt: "Please notice this role is designed to work only with RHEL/CentOS 6,7 and 8"
when: ansible_os_family != 'RedHat' or ansible_distribution == 'Fedorra'

0 comments on commit 9dec3b7

Please sign in to comment.