On 09/11/17 13:06, Mark Shuttleworth wrote:
> On 11/07/2017 03:11 PM, John Meinel wrote:
>> ...
>>  
>>
>>     > Perhaps just:
>>     >
>>     >   juju deploy --map-machines A=B,C=D
>>     >
>>     > ... or some variant of that?
>>     >
>>     > Let's use the betas to refine and condense and clarify.
>>
>>     +1 to that. I'm wondering if use-existing-machines is ever appropriate
>>     on its own, as the machine numbers in a model are ephemeral but
>>     machine numbers in a bundle are static.
>>
>>
>> Feedback from Admins that one of their big use case really is for
>> bundle-a to lay down a definition/base charm across everything, and
>> bundle-b to be meant as an exact overlay, and all of the machine-ids
>> are exact matches. And having to specify 0=0,...50=50 is a lot of ugly
>> boilerplate.
> 
> I would expect that --map-machines means that machine numbers correspond
> UNLESS remapped. So your ugly boilerplate is not needed.

Part of the problem with this is that this isn't how any of the flags
work just now.

All flags are either bool flags, which take no args, or other types that
*always* take args.

Now this isn't to say that we couldn't force something, but it isn't as
intuitive.

We could make
  --map-machines
work by itself, and we could make
  --map-machines=1=2,3=4
work, but the underlying flag parsing library wouldn't like:
  --map-machines 1=2,3=4

Because if you are a "bool" type flag, you can work without any args, or
work with an explicit arg, the second case, but it doesn't work with the
third.

Tim

-- 
Juju-dev mailing list
Juju-dev@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/juju-dev

Reply via email to