forked from GoogleCloudPlatform/gatekeeper-securitycenter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.env
45 lines (36 loc) · 2.12 KB
/
setup.env
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Source this file before running `setup.sh`.
#
# If you want to use an existing GKE cluster and/or existing Google service
# accounts instead of creating new resources, edit the values in this file to
# match the names of your existing resources.
export GOOGLE_CLOUD_APIS="iam.googleapis.com securitycenter.googleapis.com serviceusage.googleapis.com"
export ADMIN_USER=$(gcloud config list --format 'value(core.account)')
export HOST_PROJECT_ID=$(gcloud config list --format 'value(core.project)')
export MANAGED_PROJECT_ID=$HOST_PROJECT_ID
export ORGANIZATION_ID=$(gcloud projects get-ancestors "$MANAGED_PROJECT_ID" \
--format json | jq -r '.[] | select (.type=="organization") | .id')
export CLUSTER=gatekeeper-securitycenter
export CLUSTER_NODES_TAGS="gke-$CLUSTER-default-pool"
export CLOUDSDK_COMPUTE_ZONE=$(gcloud config list --format 'value(compute.zone)')
export KCC_NS=gatekeeper-securitycenter-kcc
export KCC_SA_NAME=gatekeeper-securitycenter-kcc
export KCC_SA_DISPLAY_NAME="Config Connector service account for gatekeeper-securitycenter"
export KCC_SA_ORGANIZATION_ROLES="roles/resourcemanager.organizationAdmin roles/securitycenter.findingsEditor roles/securitycenter.sourcesAdmin roles/serviceusage.serviceUsageConsumer"
export KCC_SA_PROJECT_ROLES="roles/iam.serviceAccountAdmin roles/iam.serviceAccountTokenCreator roles/iam.serviceAccountUser roles/iam.workloadIdentityUser"
export GATEKEEPER_VERSION=v3.10.0
export KPT_FN_APPLY_SETTERS_VERSION=v0.2
export FINDINGS_EDITOR_SA_NAME=gatekeeper-securitycenter
export SOURCES_ADMIN_SA_NAME=securitycenter-sources-admin