From 4b942e8ed558e4dfe378057b25a03e5a8d08c0a6 Mon Sep 17 00:00:00 2001 From: David Wragg Date: Fri, 15 May 2015 13:12:36 +0100 Subject: [PATCH] populate_1_ipam -> ipam_claim --- weave | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/weave b/weave index 10c3a766..06a3dfc7 100755 --- a/weave +++ b/weave @@ -639,7 +639,9 @@ populate_dns() { # IP Allocation Management helpers ###################################################################### -populate_1_ipam() { +# Claim addresses for a container in IPAM. Expects to be called from +# with_container_addresses. +ipam_claim() { for CIDR in $3; do # NB: CONTAINER_IP is the IP of the weave container; it is set by wait_for_status. http_call_ip $CONTAINER_IP $HTTP_PORT PUT /ip/$1/${CIDR%/*} @@ -781,7 +783,7 @@ case "$COMMAND" in wait_for_status $CONTAINER_NAME $HTTP_PORT if [ -n "$IPRANGE" ] ; then # Tell the newly-started weave IP allocator about existing weave IPs - with_container_addresses populate_1_ipam weave:expose $(docker ps -q) + with_container_addresses ipam_claim weave:expose $(docker ps -q) fi echo $CONTAINER