Remove etcd member by peerURLs (#12690)

The way to obtain the IP of a particular member is convoluted and depend
on multiple variables. The match is also textual and it's not clear
against what we're matching

It's also broken for etcd member which are not also Kubernetes nodes,
because the "Lookup node IP in kubernetes" task will fail and abort the
play.

Instead, match against 'peerURLs', which does not need new variable, and
use json output.

- Add testcase for etcd removal on external etcd
This commit is contained in:
Max Gautier
2025-11-17 10:57:40 +00:00
committed by GitHub
parent f15f58b5b9
commit ebf9fedf9b
3 changed files with 5 additions and 20 deletions

View File

@@ -120,7 +120,7 @@ run_playbook tests/testcases/100_check-k8s-conformance.yml
# Test node removal procedure
if [ "${REMOVE_NODE_CHECK}" = "true" ]; then
run_playbook remove-node.yml -e skip_confirmation=yes -e node=${REMOVE_NODE_NAME}
run_playbook remove-node.yml -e skip_confirmation=yes -e node="${REMOVE_NODE_NAME}"
fi
# Clean up at the end, this is to allow stage1 tests to include cleanup test