From 08239919de9a5fc70ca39e35e25c0a4d7bc13754 Mon Sep 17 00:00:00 2001 From: "patchback[bot]" <45432694+patchback[bot]@users.noreply.github.com> Date: Tue, 23 Jan 2024 07:29:23 +0100 Subject: [PATCH] [PR #7875/44028060 backport][stable-8] Fix: incus connection plugin treats inventory_hostname incorrectly in remote config (#7886) Fix: incus connection plugin treats inventory_hostname incorrectly in remote config (#7875) * Fixes inventory_hostname treatment as a litteral instead of inventory_hostname variable. Similar problem fixed in LXD: https://github.com/ansible-collections/community.general/pull/4912 * changelog for upsream * Update changelogs/fragments/7874-incus_connection_treats_inventory_hostname_as_literal_in_remotes.yml Co-authored-by: Felix Fontein --------- Co-authored-by: travis Co-authored-by: Felix Fontein (cherry picked from commit 44028060c3f4f325fc8ff6b7f75c501dad2d8251) Co-authored-by: Travis McCollum --- ...nnection_treats_inventory_hostname_as_literal_in_remotes.yml | 2 ++ plugins/connection/incus.py | 1 + 2 files changed, 3 insertions(+) create mode 100644 changelogs/fragments/7874-incus_connection_treats_inventory_hostname_as_literal_in_remotes.yml diff --git a/changelogs/fragments/7874-incus_connection_treats_inventory_hostname_as_literal_in_remotes.yml b/changelogs/fragments/7874-incus_connection_treats_inventory_hostname_as_literal_in_remotes.yml new file mode 100644 index 0000000000..83d302e9b9 --- /dev/null +++ b/changelogs/fragments/7874-incus_connection_treats_inventory_hostname_as_literal_in_remotes.yml @@ -0,0 +1,2 @@ +bugfixes: + - "incus connection plugin - treats ``inventory_hostname`` as a variable instead of a literal in remote connections (https://github.com/ansible-collections/community.general/issues/7874)." diff --git a/plugins/connection/incus.py b/plugins/connection/incus.py index f346d06170..81d6f971c7 100644 --- a/plugins/connection/incus.py +++ b/plugins/connection/incus.py @@ -21,6 +21,7 @@ DOCUMENTATION = """ - The instance identifier. default: inventory_hostname vars: + - name: inventory_hostname - name: ansible_host - name: ansible_incus_host executable: