New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ansible.builtin.rpm_key fails in certain cases when deleting a key #79585
Comments
Files identified in the description: If these files are incorrect, please update the |
@kkeane In |
Thank you - that is interesting to know (and a very quick response). I'll check this later today, but trust that you are right. Maybe the documentation can be improved to clarify this, or rpm_key can be updated to also handle the provided string? The confusion comes from the corresponding Linux utility rpmkeys; it documents the nearly opposite behavior in its man page (from RHEL 9.1):
Granted, the module and the utility are two unrelated things, and man rpmkeys does not use the term keyid, but such a different behavior is still surprising. |
needs_info |
@gryu7 you are right, it appears that the keyid works. I think that should change this from a bug report to a feature request? |
I'm not sure whether we should change the key value to key like 'gpg-pubkey-61a7c71d-55740c4b' from keyid.
I think it would be a good idea to ask for opinions on how to do this issue on the mailing list here. |
On item 1:
Remember that gpg-pubkey-XXXX-XXXX is already supported, just not correctly.
So the key value probably needs support both keyids and gpg-pubkey-XXXX-XXXX to avoid a breaking change.
Sent with [Proton Mail](https://proton.me/) secure email.
…------- Original Message -------
On Friday, December 16th, 2022 at 5:28 AM, gryu7 ***@***.***> wrote:
I'm not sure whether we should change the key value to key like 'gpg-pubkey-61a7c71d-55740c4b' from keyid.
I think we have 2 option.
- Change the key value to key like 'gpg-pubkey-61a7c71d-55740c4b'.
- Change the document clearly.
I think it would be a good idea to ask for opinions on how to do this issue on the mailing list [here](https://groups.google.com/forum/#!forum/ansible-devel).
—
Reply to this email directly, [view it on GitHub](#79585 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/AABY5OX4IQ3MNY6AI4S3MVDWNP4YXANCNFSM6AAAAAAS4RJ2ZU).
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Summary
When deleting a key by key ID that has already been deleted, rpm_key will fail.
Issue Type
Bug Report
Component Name
rpm_key
Ansible Version
Configuration
OS / Environment
RHEL 8
Steps to Reproduce
Expected Results
The first call to rpm_key should return failed=false and changed either true or false as appropriate
The second call to rpm_key should returned failed=false and changed=false
Actual Results
The first call will return either failed=false and changed=true if the key exists, or failed=true if the key is missing.
The second call will always return failed=true.
Code of Conduct
The text was updated successfully, but these errors were encountered: