Skip to content

Commit

Permalink
Allow any IPv6 address to be configured for provisioning, but link lo…
Browse files Browse the repository at this point in the history
…cal scope
  • Loading branch information
mvazquezc committed May 5, 2020
1 parent d8dc9c6 commit e4df693
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ironic-common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function wait_for_interface_or_ip() {
else
until [ ! -z "${IRONIC_IP}" ]; do
echo "Waiting for ${PROVISIONING_INTERFACE} interface to be configured"
export IRONIC_IP=$(ip -br addr show dev $PROVISIONING_INTERFACE | grep -Po "[^\s]+/[0-9]+" | grep -e "^fd" -e "\." | sed -e 's%/.*%%' | head -n 1)
export IRONIC_IP=$(ip -br add show scope global up dev "${PROVISIONING_INTERFACE}" | awk '{print $3; exit}')
sleep 1
done
fi
Expand Down

2 comments on commit e4df693

@yanndegat
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi @mvazquezc
there-s an issue on this commit: the ipv4 is resolved with its cidr prefix
(10.0.0.1/8 instead of 10.0.0.1)

at least:
export IRONIC_IP=$(ip -br add show scope global up dev "${PROVISIONING_INTERFACE}" | awk '{print $3; exit}' | cut -d / -f 1)

could solve the issue

@mvazquezc
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @yanndegat,

@maelk Sent a fix for that: #156

Please sign in to comment.