Quellcode durchsuchen

Preflight Check Hotfix (#3475)

sdess09 vor 2 Jahren
Ursprung
Commit
0957758e46
1 geänderte Dateien mit 3 neuen und 2 gelöschten Zeilen
  1. 3 2
      dashboard/src/components/GCPProvisionerSettings.tsx

+ 3 - 2
dashboard/src/components/GCPProvisionerSettings.tsx

@@ -59,7 +59,8 @@ type Props = RouteComponentProps & {
   clusterId?: number;
 };
 
-const VALID_CIDR_RANGE_PATTERN = /^(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.0\.0\/16$/;
+const VALID_CIDR_RANGE_PATTERN = /^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\/(8|9|1\d|2[0-8])$/;
+
 
 const GCPProvisionerSettings: React.FC<Props> = (props) => {
   const {
@@ -454,7 +455,7 @@ const GCPProvisionerSettings: React.FC<Props> = (props) => {
       )}
 
       <Button
-        disabled={isDisabled() || isLoading || preflightFailed}
+        disabled={isDisabled() || isLoading || preflightFailed || statusPreflight() != ""}
         onClick={createCluster}
         status={getStatus()}
       >