From 396d8fbcfc857f42740c5c28ce3e9f8ed3cc5824 Mon Sep 17 00:00:00 2001 From: Lenin Alevski Date: Fri, 12 Feb 2021 09:20:36 -0800 Subject: [PATCH] GCP KMS many fixes (#600) - Operator-UI didnt correctly append gcp kms configuration --- .../Console/Tenants/ListTenants/AddTenant.tsx | 23 +++---------------- restapi/consts.go | 2 +- 2 files changed, 4 insertions(+), 21 deletions(-) diff --git a/portal-ui/src/screens/Console/Tenants/ListTenants/AddTenant.tsx b/portal-ui/src/screens/Console/Tenants/ListTenants/AddTenant.tsx index ec2336201..3c9b4e3e3 100644 --- a/portal-ui/src/screens/Console/Tenants/ListTenants/AddTenant.tsx +++ b/portal-ui/src/screens/Console/Tenants/ListTenants/AddTenant.tsx @@ -17,7 +17,6 @@ import React, { useCallback, useEffect, useMemo, useState } from "react"; import debounce from "lodash/debounce"; import get from "lodash/get"; -import ModalWrapper from "../../Common/ModalWrapper/ModalWrapper"; import Grid from "@material-ui/core/Grid"; import InputBoxWrapper from "../../Common/FormComponents/InputBoxWrapper/InputBoxWrapper"; import { Button, LinearProgress, Paper, Typography } from "@material-ui/core"; @@ -27,10 +26,7 @@ import TableCell from "@material-ui/core/TableCell"; import TableRow from "@material-ui/core/TableRow"; import api from "../../../../common/api"; import { createStyles, Theme, withStyles } from "@material-ui/core/styles"; -import { - containerForHeader, - modalBasic, -} from "../../Common/FormComponents/common/styleLibrary"; +import { modalBasic } from "../../Common/FormComponents/common/styleLibrary"; import FormSwitchWrapper from "../../Common/FormComponents/FormSwitchWrapper/FormSwitchWrapper"; import SelectWrapper from "../../Common/FormComponents/SelectWrapper/SelectWrapper"; import { @@ -268,6 +264,7 @@ const AddTenant = ({ classes }: IAddTenantProps) => { vaultCert: "", vaultCA: "", gemaltoCA: "", + gcpPrivateKey: "", }); // Files States @@ -853,17 +850,6 @@ const AddTenant = ({ classes }: IAddTenantProps) => { ]; } - if (encryptionType === "gcp") { - encryptionValidation = [ - ...encryptionValidation, - { - fieldKey: "gcp_project_id", - required: true, - value: gcpProjectID, - }, - ]; - } - if (encryptionType === "aws") { encryptionValidation = [ ...encryptionValidation, @@ -1100,7 +1086,7 @@ const AddTenant = ({ classes }: IAddTenantProps) => { }, }; break; - case "GCP": + case "gcp": insertEncrypt = { gcp: { secretmanager: { @@ -2311,12 +2297,9 @@ const AddTenant = ({ classes }: IAddTenantProps) => { name="gcp_project_id" onChange={(e: React.ChangeEvent) => { setGcpProjectID(e.target.value); - clearValidationError("gcp_project_id"); }} label="Project ID" value={gcpProjectID} - error={validationErrors["gcp_project_id"] || ""} - required /> diff --git a/restapi/consts.go b/restapi/consts.go index 332037296..2309ef27c 100644 --- a/restapi/consts.go +++ b/restapi/consts.go @@ -62,7 +62,7 @@ const ( // Image versions const ( - KESImageVersion = "minio/kes:v0.13.1" + KESImageVersion = "minio/kes:v0.13.4" ConsoleImageDefaultVersion = "minio/console:v0.5.2" )