Skip to content

Commit 8fb156e

Browse files
committed
improve docs
1 parent 4219052 commit 8fb156e

File tree

3 files changed

+63
-2
lines changed

3 files changed

+63
-2
lines changed

README.md

+61-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,66 @@
55
============================
66
Ansible role to install the Extra Packages for Enterprise Linux (EPEL) - Repository on RHEL and centos.
77

8+
### What do we do here?
9+
+ First we read the variables you configured and our default values.
10+
+ If enabled *(default to false)*, we do a simple version-check that will validate that you never run a older version of this role after you run this role before.
11+
+ We validate that the GPG key of the EPEL repo for your distribution release is installed and match the fingerprint in the config.
12+
+ We install the epel repo from a remote URL.
13+
14+
### example useage of this role
15+
You can either use this role via ansible galaxy or by downloading this role manually.
16+
17+
#### ansible galaxy: install this role
18+
```bash
19+
ansible-galaxy install do1jlr.epel
20+
```
21+
22+
#### ansible-galaxy: example playbook
23+
```yml
24+
---
25+
- name: install epel release
26+
hosts: srv01.example.com
27+
roles:
28+
- do1jlr.epel
29+
```
30+
31+
#### manual download role
32+
```bash
33+
# download to your roles directory
34+
git clone https://github.com/roles-ansible/role_install-epel-release.git
35+
```
36+
37+
#### manual example playbook
38+
```yaml
39+
---
40+
- name: Install epel release
41+
hosts: srv02.example.com
42+
tags:
43+
- epel
44+
vars:
45+
submodules_versioncheck: true
46+
roles:
47+
- role_install-epel-release
48+
```
49+
50+
### variables and configuration
51+
52+
Here a our default values you can overwrite:
53+
```yaml
54+
# do we want a simple versionscheck? (true is recomended)
55+
submodules_versioncheck: false
56+
57+
# epel repo
58+
epel_repo:
59+
url: "https://dl.fedoraproject.org/pub/epel/epel-release-latest-{{ ansible_distribution_major_version }}.noarch.rpm"
60+
gpg_key_url: "https://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-{{ ansible_distribution_major_version }}"
61+
gpg_key_path: "/etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-{{ ansible_distribution_major_version }}"
62+
fingerprint:
63+
'6': "8C3B E96A F230 9184 DA5C 0DAE 3B49 DF2A 0608 B895"
64+
'7': "91E9 7D7C 4A5E 96F1 7F3E 888F 6A2F AEA2 352C 64E5"
65+
'8': "94E2 79EB 8D8F 25B2 1810 ADF1 21EA 45AB 2F86 D6A1"
66+
```
67+
868
### Testing
969
This role is tested with [these github-action](https://github.com/search?q=topic%3Acentos+topic%3Acheck-ansible+topic%3Agithub-actions+org%3Aroles-ansible&type=Repositories) tests for different versions of centos. Linting is tested via travis-ci.
1070
If you want to find out more about our tests, please have a look at the github marketplace.
@@ -26,9 +86,9 @@ WORK IN PROGRESS
2686

2787
missing:
2888
- os detection (RHEL)
29-
- docs
3089

3190
working:
91+
- docs
3292
- epel install on centos 7
3393
- github-actions
3494
- vars

defaults/main.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
---
2+
# do we want a simple versionscheck? (true is recomended)
23
submodules_versioncheck: false
34
# epel repo
45
epel_repo:

vars/main.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
playbook_version_number: 1025 # should be over ninethousand
2+
playbook_version_number: 1026 # should be over ninethousand
33
playbook_version_path: 'role-epel_roles-ansible_github.com.version'
44
# epel repo
55
_epel_repo:

0 commit comments

Comments
 (0)