This repository has been archived by the owner on Jun 20, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 673
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pt 2 of #657 (comment) still needs doing. |
@bboreham requests that, instead of shelling out, we use the weave HTTP api to determine the ipam CIDR. I agree. Will add that to this PR. |
Pass `-e WEAVE_CIDR=` to your container to use IPAM. If IPAM is not enabled on the weave router, the container will be booted without weave networking. I'm not crazy about adding *another* undocumented weave cli command (ipam-cidr), but it saves the proxy messing around finding container IPs.
@@ -10,8 +10,8 @@ start_suite "Proxy registers containers with dns" | |||
|
|||
weave_on $HOST1 launch-dns 10.2.254.1/24 | |||
weave_on $HOST1 launch-proxy --with-dns | |||
docker_proxy_on $HOST1 run -e WEAVE_CIDR=$C2/24 -dt --name=c2 -h $NAME gliderlabs/alpine /bin/sh | |||
docker_proxy_on $HOST1 run -e WEAVE_CIDR=$C1/24 -dt --name=c1 aanand/docker-dnsutils /bin/sh | |||
proxy docker_on $HOST1 run -e WEAVE_CIDR=$C2/24 -dt --name=c2 -h $NAME gliderlabs/alpine /bin/sh |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
weave_on $HOST2 launch -iprange $UNIVERSE $HOST1 | ||
weave_on $HOST2 launch-proxy --ipam | ||
|
||
proxy start_container $HOST1 -e WEAVE_CIDR= --name=c1 |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
|
||
host1$ docker run -e WEAVE_CIDR= -ti ubuntu /bin/sh | ||
|
||
Alternatively, to enable automatic allocation of all containers without a `WEAVE_CIDR`, we can launch the proxy with the `--ipam` option. For example: |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
rade
added a commit
that referenced
this pull request
May 23, 2015
Proxy support for IPAM Closes #657.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pass
-e WEAVE_CIDR=
to your container to use IPAM. If IPAM is notenabled on the weave router, the container will be booted without weave
networking.
I'm not crazy about adding another undocumented weave cli command(ipam-cidr), but it saves the proxy messing around finding container
IPs.
Fixes #657