damondouglas commented on code in PR #30847: URL: https://github.com/apache/beam/pull/30847#discussion_r1566090575
########## .test-infra/terraform/google-cloud-platform/utility-cluster/strimzi-contoller.tf: ########## @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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. + */ + +resource "helm_release" "strimzi-helm-release" { + name = "strimzi" + namespace = "strimzi" + create_namespace = true + repository = "https://strimzi.io/charts/" + chart = "strimzi-kafka-operator" + version = "0.40.0" + + atomic = "true" + timeout = 500 + + set { + name = "watchAnyNamespace" + value = "true" + } + depends_on = [ module.gke.google_container_cluster ] +} + Review Comment: This could be in its own module separate from the GKE cluster provisioning. ########## .test-infra/terraform/google-cloud-platform/google-kubernetes-engine/outputs.tf: ########## @@ -0,0 +1,26 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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. + */ + +output kubernetes_api_endpoint { + value = google_container_cluster.default.endpoint +} + +output cluster_ca_certificate { Review Comment: I think the provisioning of the Kubernetes cluster and any workloads that depend on it should be in separate terraform modules. Then one would just follow typical gcloud command to connect. ########## .test-infra/terraform/google-cloud-platform/utility-cluster/gke.tf: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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. + */ + +module "gke" { + source = "../google-kubernetes-engine" + project = "apache-beam-testing" + network = "default" + subnetwork = "default-f91f013bcf8bd369" + region = "us-central1" + cluster_name_prefix = "beam-utility" + service_account_id = "[email protected]" + cluster_name_override = "beam-utility" Review Comment: Maybe one can just create a new `tfvars` file storing these values and have the workflow involve provisioning the Kubernetes cluster first, separate from the strimzi workload. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
