Sfoglia il codice sorgente

update azure provisioning version and instance types (#3429)

Co-authored-by: David Townley <davidtownley@Davids-MacBook-Air.local>
d-g-town 2 anni fa
parent
commit
20c5b89edc

+ 10 - 10
dashboard/src/components/AzureCostConsent.tsx

@@ -53,7 +53,7 @@ const AzureCostConsent: React.FC<Props> = ({
           noWrapper
           noWrapper
           expandText="[+] Show details"
           expandText="[+] Show details"
           collapseText="[-] Hide details"
           collapseText="[-] Hide details"
-          Header={<Cost>$411.72 / mo</Cost>}
+          Header={<Cost>$314.92 / mo</Cost>}
           ExpandedSection={
           ExpandedSection={
             <>
             <>
               <Spacer height="15px" />
               <Spacer height="15px" />
@@ -62,21 +62,21 @@ const AzureCostConsent: React.FC<Props> = ({
                 <Spacer height="15px" />
                 <Spacer height="15px" />
                 • Amazon EC2:
                 • Amazon EC2:
                 <Spacer height="15px" />
                 <Spacer height="15px" />
-                <Tab />+ System workloads: Standard_A2_v2 instance (2) =
-                $132.86/mo
+                <Tab />+ System workloads: Standard_D2ps_v5 instance (2) =
+                $110.88/mo
                 <Spacer height="15px" />
                 <Spacer height="15px" />
-                <Tab />+ Monitoring workloads: Standard_A4_v2 instance (1) =
-                $139.43/mo
+                <Tab />+ Monitoring workloads: Standard_A2_v2 instance (1) =
+                $65.52/mo
                 <Spacer height="15px" />
                 <Spacer height="15px" />
                 <Tab />+ Application workloads: Standard_A2_v2 instance (1) =
                 <Tab />+ Application workloads: Standard_A2_v2 instance (1) =
-                $66.43/mo
+                $65.52/mo
               </Fieldset>
               </Fieldset>
             </>
             </>
           }
           }
         />
         />
         <Spacer y={1} />
         <Spacer y={1} />
         <Text color="helper">
         <Text color="helper">
-          The base Azure infrastructure covers up to 2 vCPU and 4GB of RAM.
+          The base Azure infrastructure covers up to 2 vCPU and 4GB of RAM for application workloads.
           Separate from the Azure cost, Porter charges based on your resource
           Separate from the Azure cost, Porter charges based on your resource
           usage.
           usage.
         </Text>
         </Text>
@@ -103,12 +103,12 @@ const AzureCostConsent: React.FC<Props> = ({
         <Spacer y={0.5} />
         <Spacer y={0.5} />
         <Text color="helper">
         <Text color="helper">
           All Azure resources will be automatically deleted when you delete your
           All Azure resources will be automatically deleted when you delete your
-          Porter project. Please enter the Azure base cost ("411.72") below to
+          Porter project. Please enter the Azure base cost ("314.92") below to
           proceed:
           proceed:
         </Text>
         </Text>
         <Spacer y={1} />
         <Spacer y={1} />
         <Input
         <Input
-          placeholder="411.72"
+          placeholder="314.92"
           value={confirmCost}
           value={confirmCost}
           setValue={setConfirmCost}
           setValue={setConfirmCost}
           width="100%"
           width="100%"
@@ -116,7 +116,7 @@ const AzureCostConsent: React.FC<Props> = ({
         />
         />
         <Spacer y={1} />
         <Spacer y={1} />
         <Button
         <Button
-          disabled={confirmCost !== "411.72"}
+          disabled={confirmCost !== "314.92"}
           onClick={() => {
           onClick={() => {
             setShowCostConfirmModal(false);
             setShowCostConfirmModal(false);
             setConfirmCost("");
             setConfirmCost("");

+ 9 - 6
dashboard/src/components/AzureProvisionerSettings.tsx

@@ -40,7 +40,7 @@ const machineTypeOptions = [
   { value: "Standard_A4_v2", label: "Standard_A4_v2" },
   { value: "Standard_A4_v2", label: "Standard_A4_v2" },
 ];
 ];
 
 
-const clusterVersionOptions = [{ value: "v1.24.9", label: "v1.24.9" }];
+const clusterVersionOptions = [{ value: "v1.26.6", label: "v1.26.6" },{ value: "v1.24.9", label: "v1.24.9" }];
 
 
 type Props = RouteComponentProps & {
 type Props = RouteComponentProps & {
   selectedClusterVersion?: Contract;
   selectedClusterVersion?: Contract;
@@ -68,7 +68,7 @@ const AzureProvisionerSettings: React.FC<Props> = (props) => {
   const [minInstances, setMinInstances] = useState(1);
   const [minInstances, setMinInstances] = useState(1);
   const [maxInstances, setMaxInstances] = useState(10);
   const [maxInstances, setMaxInstances] = useState(10);
   const [cidrRange, setCidrRange] = useState("10.78.0.0/16");
   const [cidrRange, setCidrRange] = useState("10.78.0.0/16");
-  const [clusterVersion, setClusterVersion] = useState("v1.24.9");
+  const [clusterVersion, setClusterVersion] = useState("v1.26.6");
   const [isReadOnly, setIsReadOnly] = useState(false);
   const [isReadOnly, setIsReadOnly] = useState(false);
   const [errorMessage, setErrorMessage] = useState<string>("");
   const [errorMessage, setErrorMessage] = useState<string>("");
   const [errorDetails, setErrorDetails] = useState<string>("");
   const [errorDetails, setErrorDetails] = useState<string>("");
@@ -130,6 +130,9 @@ const AzureProvisionerSettings: React.FC<Props> = (props) => {
     if (!VALID_CIDR_RANGE_PATTERN.test(cidrRange)) {
     if (!VALID_CIDR_RANGE_PATTERN.test(cidrRange)) {
       return "VPC CIDR range must be in the format of [0-255].[0-255].0.0/16";
       return "VPC CIDR range must be in the format of [0-255].[0-255].0.0/16";
     }
     }
+    if (clusterVersion == "v1.24.9") {
+        return "Cluster version v1.24.9 is no longer supported";
+    }
 
 
     return "";
     return "";
   }
   }
@@ -152,19 +155,19 @@ const AzureProvisionerSettings: React.FC<Props> = (props) => {
           case: "aksKind",
           case: "aksKind",
           value: new AKS({
           value: new AKS({
             clusterName: clusterName,
             clusterName: clusterName,
-            clusterVersion: clusterVersion || "v1.24.9",
+            clusterVersion: clusterVersion || "v1.26.6",
             cidrRange: cidrRange || "10.78.0.0/16",
             cidrRange: cidrRange || "10.78.0.0/16",
             location: azureLocation,
             location: azureLocation,
             nodePools: [
             nodePools: [
               new AKSNodePool({
               new AKSNodePool({
-                instanceType: "Standard_A2_v2",
+                instanceType: "Standard_D2ps_v5",
                 minInstances: 1,
                 minInstances: 1,
                 maxInstances: 3,
                 maxInstances: 3,
                 nodePoolType: NodePoolType.SYSTEM,
                 nodePoolType: NodePoolType.SYSTEM,
                 mode: "User",
                 mode: "User",
               }),
               }),
               new AKSNodePool({
               new AKSNodePool({
-                instanceType: "Standard_A4_v2",
+                instanceType: "Standard_A2_v2",
                 minInstances: 1,
                 minInstances: 1,
                 maxInstances: 3,
                 maxInstances: 3,
                 nodePoolType: NodePoolType.MONITORING,
                 nodePoolType: NodePoolType.MONITORING,
@@ -372,7 +375,7 @@ const AzureProvisionerSettings: React.FC<Props> = (props) => {
               disabled={isReadOnly}
               disabled={isReadOnly}
               value={maxInstances}
               value={maxInstances}
               setValue={(x: number) => setMaxInstances(x)}
               setValue={(x: number) => setMaxInstances(x)}
-              label="Maximum number of application EC2 instances"
+              label="Maximum number of application nodes"
               placeholder="ex: 1"
               placeholder="ex: 1"
             />
             />
             <InputRow
             <InputRow