Skip to content

Rename connection probe task to reflect its actual purpose#1676

Merged
swalkinshaw merged 1 commit into
masterfrom
rename-connection-probe-task
Jun 22, 2026
Merged

Rename connection probe task to reflect its actual purpose#1676
swalkinshaw merged 1 commit into
masterfrom
rename-connection-probe-task

Conversation

@swalkinshaw

Copy link
Copy Markdown
Member

Fixes #1466

The task named "Check whether Ansible can connect as " reads like a connectivity gate, but it is not one: failed_when: false is required for the root -> admin_user fallback, so the task is really detecting which remote user to use, not asserting that SSH works. Genuine SSH failures are intentionally surfaced by Ansible's own later connection error rather than duplicated here.

Rename it to "Determine remote user by probing connection as " so the name stops advertising a guarantee it never made.

The task named "Check whether Ansible can connect as <user>" reads like a
connectivity gate, but it is not one: `failed_when: false` is required
for the root -> admin_user fallback, so the task is really detecting which
remote user to use, not asserting that SSH works. Genuine SSH failures are
intentionally surfaced by Ansible's own later connection error rather than
duplicated here.

Rename it to "Determine remote user by probing connection as <user>" so the
name stops advertising a guarantee it never made. No behavior change.

Refs #1466
@swalkinshaw swalkinshaw merged commit b5cd2c3 into master Jun 22, 2026
2 checks passed
@swalkinshaw swalkinshaw deleted the rename-connection-probe-task branch June 22, 2026 18:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: Check whether Ansible can connect as <user> – passes when SSH connection fails

1 participant