From 2d7302ba12b6d73b23395761b2e286404e67a5b6 Mon Sep 17 00:00:00 2001 From: "patchback[bot]" <45432694+patchback[bot]@users.noreply.github.com> Date: Sun, 15 Aug 2021 13:33:00 +0200 Subject: [PATCH] Add ipv4 example to linode inventory docs (#3200) (#3209) * Add ipv4 example to linode inventory * Update plugins/inventory/linode.py Co-authored-by: Felix Fontein Co-authored-by: Felix Fontein (cherry picked from commit 432c89148721b4a4598cb20d9569aa9bbdac1f2b) Co-authored-by: Paul Hauner --- plugins/inventory/linode.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugins/inventory/linode.py b/plugins/inventory/linode.py index c2dcac5392..177bd0a42a 100644 --- a/plugins/inventory/linode.py +++ b/plugins/inventory/linode.py @@ -78,6 +78,10 @@ groups: webservers: "'web' in (tags|list)" mailservers: "'mail' in (tags|list)" compose: + # By default, Ansible tries to connect to the label of the instance. + # Since that might not be a valid name to connect to, you can + # replace it with the first IPv4 address of the linode as follows: + ansible_ssh_host: ipv4[0] ansible_port: 2222 '''