Uploaded image for project: 'Ansible Automation Platform RFEs'
  1. Ansible Automation Platform RFEs
  2. AAPRFE-1201

[contructed inventory] Ensure that Global Inventory Variables are applied only to hosts from that source

XMLWordPrintable

    • Icon: Feature Request Feature Request
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • 2.15
    • controller
    • False
    • Hide

      None

      Show
      None
    • False

      When the sources from a constructed inventory have global variables as per the example below, the variables are applied to all hosts referencing the settings from the last inventory source selected.

      Inventory A: ansible_ssh_common_args: "-o ProxyCommand='ssh -W %h:%p -q root@proxyhost1'"
      Inventory B: ansible_ssh_common_args: "-o ProxyCommand='ssh -W %h:%p -q root@proxyhost2'"
      Constructed inventory: Inventory order 1.Inventory A, 2. Inventory B
      Host A present in only in inventory A.
      The ansible_ssh_common_args from Inventory B are used when connecting to the hosts
      

      It would be great to implement an option to customize the behavior.

      Suggestions:

      • Allow users to apply the source variables only to the hosts that are from that specific source.
      • Automatically move source variables to host level when syncing

              bcoursen@redhat.com Brian Coursen
              lbenedit1@redhat.com Lucas Benedito
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: