I'm trying to remove apt_key
I added using ansible
- name: Ensure an helm signing key is present
apt_key:
url: https://baltocdn.com/helm/signing.asc
become: true
and this is what I want to do
- name: Ensure helm signing key is removed
apt_key:
url: https://baltocdn.com/helm/signing.asc
state: absent
become: true
fatal: [master]: FAILED! => {"changed": false, "msg": "key is required"}
My question is, is there an ansible module way to get the key
value or only using command
to extract the value from apt_key list
? any suggestion, please.
It will be very helpful for me if you include a code sample as well.
Thank you.
question from:
https://stackoverflow.com/questions/65910162/ansible-removing-gpg-key-on-ubuntu 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…