Feroze Mohideen 2 gadi atpakaļ
vecāks
revīzija
b6feb6ce95

+ 0 - 3
api/server/handlers/project_integration/preflight_check.go

@@ -1,7 +1,6 @@
 package project_integration
 
 import (
-	"fmt"
 	"net/http"
 
 	"connectrpc.com/connect"
@@ -111,8 +110,6 @@ func (p *CreatePreflightCheckHandler) ServeHTTP(w http.ResponseWriter, r *http.R
 		return
 	}
 
-	fmt.Printf("here are the ccp prefligt checks: %+v\n", checkResp.Msg.PreflightChecks)
-
 	errors := []PreflightCheckError{}
 	for key, val := range checkResp.Msg.PreflightChecks {
 		if val.Message == "" || !contains(recognizedPreflightCheckKeys, key) {

+ 1 - 87
dashboard/src/lib/hooks/useCluster.ts

@@ -366,93 +366,7 @@ export const useUpdateCluster = ({
       const preflightCheckResp = await api.preflightCheck(
         "<token>",
         new PreflightCheckRequest({
-          contract: {
-            cluster: {
-              projectId: 37,
-              clusterId: 0,
-              kind: "ENUM_KUBERNETES_KIND_EKS",
-              cloudProvider: "ENUM_CLOUD_PROVIDER_AWS",
-              cloudProviderCredentialsId:
-                "arn:aws:iam::844966915049:role/porter-manager",
-              kindValues: {
-                case: "eksKind",
-                value: {
-                  clusterName: "feroze-feb18-cluster-h0b7x4",
-                  clusterVersion: "v1.27.0",
-                  cidrRange: "10.78.0.0/16",
-                  region: "us-east-2",
-                  nodeGroups: [
-                    {
-                      instanceType: "t3.medium",
-                      minInstances: 1,
-                      maxInstances: 5,
-                      nodeGroupType: "NODE_GROUP_TYPE_SYSTEM",
-                      isStateful: false,
-                      additionalPolicies: [],
-                      additionalTaints: [],
-                    },
-                    {
-                      instanceType: "t3.large",
-                      minInstances: 1,
-                      maxInstances: 1,
-                      nodeGroupType: "NODE_GROUP_TYPE_MONITORING",
-                      isStateful: true,
-                      additionalPolicies: [],
-                      additionalTaints: [],
-                    },
-                    {
-                      instanceType: "t3.medium",
-                      minInstances: 1,
-                      maxInstances: 10,
-                      nodeGroupType: "NODE_GROUP_TYPE_APPLICATION",
-                      isStateful: false,
-                      additionalPolicies: [],
-                      additionalTaints: [],
-                    },
-                    {
-                      instanceType: "g4dn.xlarge",
-                      minInstances: 0,
-                      maxInstances: 5,
-                      nodeGroupType: "NODE_GROUP_TYPE_CUSTOM",
-                      isStateful: false,
-                      additionalPolicies: [],
-                      additionalTaints: [],
-                    },
-                  ],
-                  loadBalancer: {
-                    loadBalancerType: "LOAD_BALANCER_TYPE_NLB",
-                    wildcardDomain: "",
-                    allowlistIpRanges: "",
-                    enableWafv2: false,
-                    wafv2Arn: "",
-                    additionalCertificateArns: [],
-                    tags: {},
-                    enableS3AccessLogs: false,
-                  },
-                  enableGuardDuty: false,
-                  logging: {
-                    enableApiServerLogs: false,
-                    enableAuthenticatorLogs: false,
-                    enableSchedulerLogs: false,
-                    enableAuditLogs: false,
-                    enableControllerManagerLogs: false,
-                    enableCloudwatchLogsToS3: false,
-                  },
-                  enableKmsEncryption: false,
-                  network: {
-                    vpcCidr: "10.78.0.0/16",
-                    serviceCidr: "172.20.0.0/16",
-                  },
-                  enableEcrScanning: false,
-                },
-                isSoc2Compliant: false,
-              },
-            },
-            complianceProfiles: {
-              soc2: false,
-              hipaa: false,
-            },
-          },
+          contract: newContract,
         }),
         {
           id: projectId,