public GatewayGetOperationStatusResponse ResizeGateway(string vnetName, GatewaySKU gatewaySKU) { ResizeGatewayParameters parameters = new ResizeGatewayParameters() { GatewaySKU = gatewaySKU, }; return(client.Gateways.Resize(vnetName, parameters)); }
public override void ExecuteCmdlet() { string gatewayType = "UltraPerformance"; string warningMsg = string.Empty; string continueMsg = string.Empty; bool force = true; if (GatewaySKU.Trim().Replace(" ", "").Equals(gatewayType, StringComparison.InvariantCultureIgnoreCase)) { warningMsg = Resources.UltraPerformanceGatewayWarning; continueMsg = Resources.UltraPerformanceGatewayContinue; force = false; } if (this.Force.IsPresent) { force = true; } ConfirmAction( force, warningMsg, continueMsg, GatewaySKU + " " + GatewayType, () => { var gateway = Client.CreateVirtualNetworkGateway( VNetName, GatewayName, GatewayType, GatewaySKU, Location, VnetId, Asn, PeerWeight); WriteVerboseWithTimestamp(Resources.UltraPerformanceGatewaySucceed); WriteObject(gateway); }); }
public GatewayGetOperationStatusResponse CreateGateway(string vnetName, GatewayType gatewayType, GatewaySKU gatewaySKU) { GatewayCreateParameters parameters = new GatewayCreateParameters() { GatewayType = gatewayType, GatewaySKU = gatewaySKU, }; return(client.Gateways.Create(vnetName, parameters)); }