From f2c0969d2789814b67041cc3464c56d9477dd844 Mon Sep 17 00:00:00 2001 From: Andreas Olsson Date: Sun, 20 Aug 2017 09:00:39 +0200 Subject: [PATCH] Clarify the apt_key module's absent state behavior Currently the apt_key module only supports removing keys based on explicitly stated key ids. The documentation should reflect that. Related to #26005 --- lib/ansible/modules/packaging/os/apt_key.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/ansible/modules/packaging/os/apt_key.py b/lib/ansible/modules/packaging/os/apt_key.py index 7ba9999a988..115a6b42f38 100644 --- a/lib/ansible/modules/packaging/os/apt_key.py +++ b/lib/ansible/modules/packaging/os/apt_key.py @@ -32,7 +32,7 @@ options: required: false default: none description: - - identifier of key. Including this allows check mode to correctly report the changed state. + - identifier of key. Including this allows check mode to correctly report the changed state. Required when C(state) is set to C(absent). - "If specifying a subkey's id be aware that apt-key does not understand how to remove keys via a subkey id. Specify the primary key's id instead." data: required: false @@ -94,11 +94,6 @@ EXAMPLES = ''' url: "https://ftp-master.debian.org/keys/archive-key-6.0.asc" state: present -# Remove an Apt signing key, uses whichever key is at the URL -- apt_key: - url: "https://ftp-master.debian.org/keys/archive-key-6.0.asc" - state: absent - # Remove a Apt specific signing key, leading 0x is valid - apt_key: id: 0x473041FA