<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Fri, Oct 7, 2016 at 11:31 PM Mark Shuttleworth <<a href="mailto:mark@ubuntu.com">mark@ubuntu.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi folks<br class="gmail_msg"><br><br class="gmail_msg"><br>My AWS account pre-dates VPCs, so I didn't have one by default. I've now<br class="gmail_msg"><br>added one, how can I update my credential / controller to make use of it<br class="gmail_msg"><br>by default?<br class="gmail_msg"></blockquote><div><br></div><div>At the moment the only way to use a non-default VPC is to specify it explicitly when bootstrapping or adding a model, using "--config vpc-id=vpc-xyz". There are some requirements for the VPC, which bootstrap will inform you of if they are not met. The error message is pasted below. A couple of additional things I found while trying it out just now:</div><div> - you should have a subnet for each availability zone<br></div><div> - to create "default route", set the destination as <a href="http://0.0.0.0/0">0.0.0.0/0</a>. Your routes should look like:</div><div><table class="inbox-inbox-GF-WOQSCID" style="font-size:13px;margin:5px;border-collapse:collapse;color:rgb(68,68,68);font-family:"helvetica neue",roboto,arial,sans-serif"><tbody><tr class="inbox-inbox-GF-WOQSCGE" style="border-collapse:collapse"><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCFE" style="padding:0px;border-bottom:1px solid rgb(204,204,204);font-weight:bold;border-top:1px solid rgb(255,255,255);line-height:40px;overflow:hidden;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;background-color:initial;vertical-align:top;white-space:nowrap"><div class="inbox-inbox-gwt-Label" style="border-left:1px solid rgb(255,255,255);border-right:1px solid rgb(204,204,204);padding:0px 10px">Destination</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCFE" style="padding:0px;border-bottom:1px solid rgb(204,204,204);font-weight:bold;border-top:1px solid rgb(255,255,255);line-height:40px;overflow:hidden;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;background-color:initial;vertical-align:top;white-space:nowrap"><div class="inbox-inbox-gwt-Label" style="border-left:1px solid rgb(255,255,255);border-right:1px solid rgb(204,204,204);padding:0px 10px">Target</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCFE" style="padding:0px;border-bottom:1px solid rgb(204,204,204);font-weight:bold;border-top:1px solid rgb(255,255,255);line-height:40px;overflow:hidden;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;background-color:initial;vertical-align:top;white-space:nowrap"><div class="inbox-inbox-gwt-Label" style="border-left:1px solid rgb(255,255,255);border-right:1px solid rgb(204,204,204);padding:0px 10px">Status</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCFE" style="padding:0px;border-bottom:1px solid rgb(204,204,204);font-weight:bold;border-top:1px solid rgb(255,255,255);line-height:40px;overflow:hidden;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;background-color:initial;vertical-align:top;white-space:nowrap"><div class="inbox-inbox-gwt-Label" style="border-left:1px solid rgb(255,255,255);border-right:1px solid rgb(204,204,204);padding:0px 10px">Propagated</div></td></tr><tr class="inbox-inbox-GF-WOQSCJE" style="line-height:20px"><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label"><a href="http://10.0.0.0/16">10.0.0.0/16</a></div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label">local</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label inbox-inbox-GF-WOQSCFBC" style="color:rgb(0,153,51)">Active</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label">No</div></td></tr><tr class="inbox-inbox-GF-WOQSCJE" style="line-height:20px"><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label"><a href="http://0.0.0.0/0">0.0.0.0/0</a></div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><a class="inbox-inbox-gwt-Anchor" href="https://console.aws.amazon.com/vpc/home?region=us-east-1#igws:filter=igw-5bd2103c" style="color:rgb(17,102,187);text-decoration:none;border-radius:2px;padding:1px 2px;background-color:transparent">igw-5bd2103c</a></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label inbox-inbox-GF-WOQSCFBC" style="color:rgb(0,153,51)">Active</div></td><td colspan="1" rowspan="1" align="left" class="inbox-inbox-GF-WOQSCIE" style="padding:5px 6px;border-bottom:1px solid rgb(224,224,224);vertical-align:top"><div class="inbox-inbox-gwt-Label">No</div></td></tr></tbody></table></div><div><br></div><div>We'll be making this all automatic. If it can, Juju will create a suitable VPC, subnets, etc. for you to use, and then use it without you having to specify any config.</div><div><br></div><div>Cheers,</div><div>Andrew</div><div><br></div><div>"""</div><div><div>The given vpc-id does not meet one or more of the following minimum</div><div>Juju requirements:</div><div><br></div><div>1. VPC should be in "available" state and contain one or more subnets.</div><div>2. An Internet Gateway (IGW) should be attached to the VPC.</div><div>3. The main route table of the VPC should have both a default route</div><div>   to the attached IGW and a local route matching the VPC CIDR block.</div><div>4. At least one of the VPC subnets should have MapPublicIPOnLaunch</div><div>   attribute enabled (i.e. at least one subnet needs to be 'public').</div><div>5. All subnets should be implicitly associated to the VPC main route</div><div>   table, rather than explicitly to per-subnet route tables.</div><div><br></div><div>A default VPC already satisfies all of the requirements above. If you</div><div>still want to use the VPC, try running 'juju bootstrap' again with:</div><div><br></div><div>  --config vpc-id=%s --config vpc-id-force=true</div><div><br></div><div>to force Juju to bypass the requirements check (NOT recommended unless</div><div>you understand the implications: most importantly, not being able to</div><div>access the Juju controller, likely causing bootstrap to fail, or trying</div><div>to deploy exposed workloads on instances started in private or isolated</div><div>subnets).</div></div><div>"""</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>Mark<br class="gmail_msg"><br><br class="gmail_msg"><br><br class="gmail_msg"><br>--<br class="gmail_msg"><br>Juju mailing list<br class="gmail_msg"><br><a href="mailto:Juju@lists.ubuntu.com" class="gmail_msg" target="_blank">Juju@lists.ubuntu.com</a><br class="gmail_msg"><br>Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju" rel="noreferrer" class="gmail_msg" target="_blank">https://lists.ubuntu.com/mailman/listinfo/juju</a><br class="gmail_msg"><br></blockquote></div></div>