Skip to content

delegate_to "{{ group_name[0] }}" doesn't work when connect to host via ssh jump-host #1032

@evgeny-bushuev-incountry

Description

Bug description

TASK [vitabaks.autobase.deploy_finish : Get Postgres databases: main.yml] ************************************************************
Friday 30 May 2025  05:56:56 +0000 (0:00:07.721)       0:09:30.317 ************
fatal: [db-192-168-80-4 -> db-192-168-80-3]: UNREACHABLE! => {"changed": false, "msg": "EOF on stream; last 100 lines received:\n\rNone@bastion-ip's password: \n\rNone@bastion-ip's password: \n\rNone@bastion-ip's password: ", "unreachable": true}

Expected behavior

task finishes successfully

Steps to reproduce

  1. Provision jump-host with public access
  2. Provision db hosts with private ip addresses
  3. Configure connection to db hosts via jump-host in ansible
  4. Get an error with delegate_to tasks
    ...

Installation method

Command line

System info

Ubuntu 24.04
Ansible 11

Additional info

Since this case is kind of rare, I will suggest a PR myself

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions