Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Allow multiple CIDR arguments to run/start/attach/detach #498

Merged
merged 19 commits into from
Apr 1, 2015

Conversation

awh
Copy link
Contributor

@awh awh commented Mar 30, 2015

Addresses #467.

@rade
Copy link
Member

rade commented Mar 30, 2015

docs need updating

with_container_netns $CONTAINER attach $CIDR >/dev/null
tell_dns PUT $CONTAINER $CIDR
with_container_netns $CONTAINER attach $CIDRS >/dev/null
for CIDR in $CIDRS; do

This comment was marked as abuse.

@awh awh changed the title 467 multi cidr launch Allow multiple CIDR arguments to run/start/attach/detach Mar 30, 2015
@awh
Copy link
Contributor Author

awh commented Mar 30, 2015

Updated documentation and factored out some common parts. Unfortunately the CIDR collection loop is still resisting (see my comment elsewhere) - remaining avenues are the CPS transform that @dpw mentioned or a function that exports two global variables:

collect_cidr_args
shift $GLOBAL_CIDR_COUNT
# use $GLOBAL_CIDR_ARGS

Thoughts @rade?

host1# weave run 10.2.2.1/24 10.2.3.1/24 -t -i ubuntu

In this case, all of the addresses are added to the container's
weave interface before it is brought up.

This comment was marked as abuse.

@rade
Copy link
Member

rade commented Mar 30, 2015

Two globals is fine. No need for the 'GLOBAL_' prefix; all our vars are global.

@awh
Copy link
Contributor Author

awh commented Mar 30, 2015

Docs updated, CIDR parsing refactored.

@rade
Copy link
Member

rade commented Mar 30, 2015

Any reason not do do 'expose' and 'hide' too?

@awh
Copy link
Contributor Author

awh commented Mar 31, 2015

weave expose and weave hide now accept multiple addresses.

@awh
Copy link
Contributor Author

awh commented Mar 31, 2015

Docs updated to use consistent subnets in examples.

@awh
Copy link
Contributor Author

awh commented Mar 31, 2015

I'm going to have a stab at rebasing this to clean up the history - please hold off merging for now.

@rade
Copy link
Member

rade commented Mar 31, 2015

I really don't care. But if you must...

rade added a commit that referenced this pull request Apr 1, 2015
Allow multiple CIDR arguments to run/start/attach/detach/expose/hide

Closes #467.
@rade rade merged commit 254b837 into weaveworks:master Apr 1, 2015
@rade rade removed the in progress label Apr 1, 2015
rade added a commit that referenced this pull request Apr 16, 2015
@rade rade modified the milestone: 0.10.0 Apr 18, 2015
@awh awh deleted the 467_multi_cidr_launch branch April 28, 2015 14:18
rade added a commit that referenced this pull request Aug 5, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants