mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 21:00:22 -07:00
* Changed rpm-keyid extraction and verification method * minor style fixes * fixed rpm key deletion,added integration test for mono key,fixed wording in integration tests
This commit is contained in:
parent
d1d0cd5406
commit
b8d371ca8b
2 changed files with 47 additions and 37 deletions
|
@ -9,6 +9,11 @@
|
|||
url: https://download.fedoraproject.org/pub/epel/7/x86_64/s/sl-5.02-1.el7.x86_64.rpm
|
||||
dest: /tmp/sl.rpm
|
||||
|
||||
- name: download Mono key
|
||||
get_url:
|
||||
url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
|
||||
dest: /tmp/mono.gpg
|
||||
|
||||
- name: remove EPEL GPG key from keyring
|
||||
rpm_key:
|
||||
state: absent
|
||||
|
@ -25,26 +30,41 @@
|
|||
- "'MISSING KEYS' in sl_check.stdout"
|
||||
- "sl_check.failed"
|
||||
|
||||
- name: remove EPEL GPG key from keyring (Idempotant)
|
||||
- name: remove EPEL GPG key from keyring (idempotent)
|
||||
rpm_key:
|
||||
state: absent
|
||||
key: /tmp/RPM-GPG-KEY-EPEL-7
|
||||
register: idempotant_test
|
||||
register: idempotent_test
|
||||
|
||||
- name: check Idempotant
|
||||
- name: check idempontence
|
||||
assert:
|
||||
that: "not idempotant_test.changed"
|
||||
that: "not idempotent_test.changed"
|
||||
|
||||
- name: add EPEL GPG key to key ring
|
||||
rpm_key:
|
||||
state: present
|
||||
key: /tmp/RPM-GPG-KEY-EPEL-7
|
||||
|
||||
- name: add EPEL GPG key to key ring (Idempotant)
|
||||
- name: add EPEL GPG key to key ring (idempotent)
|
||||
rpm_key:
|
||||
state: present
|
||||
key: /tmp/RPM-GPG-KEY-EPEL-7
|
||||
|
||||
- name: add Mono gpg key
|
||||
rpm_key:
|
||||
state: present
|
||||
key: /tmp/mono.gpg
|
||||
|
||||
- name: add Mono gpg key
|
||||
rpm_key:
|
||||
state: present
|
||||
key: /tmp/mono.gpg
|
||||
register: mono_indempotence
|
||||
|
||||
- name: verify idempotence
|
||||
assert:
|
||||
that: "not mono_indempotence.changed"
|
||||
|
||||
- name: check GPG signature of sl. Should return okay
|
||||
shell: "rpm --checksig /tmp/sl.rpm"
|
||||
register: sl_check
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue