Skip to content

Commit 94ed3ec

Browse files
authored
Redhat : Refresh Datadog repository cache (#478)
1 parent 3c2c471 commit 94ed3ec

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tasks/pkg-redhat.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,16 @@
146146
warn: no
147147
when: repofile5.changed or repofile6.changed or repofile7.changed or repofilecustom.changed
148148

149+
# On certain version of dnf, gpg keys aren't imported into the local db with the package install task.
150+
# This rule assures that they are correctly imported into the local db and users won't have to manually accept
151+
# them if running dnf commands on the hosts.
152+
- name: Refresh Datadog repository cache # noqa 503
153+
command: yum -y makecache --disablerepo="*" --enablerepo=datadog
154+
failed_when: false
155+
args:
156+
warn: no
157+
when: repofile5.changed or repofile6.changed or repofile7.changed or repofilecustom.changed
158+
149159
- name: Remove old yum repo files
150160
yum_repository:
151161
name: "ansible_datadog_{{ item }}"

0 commit comments

Comments
 (0)