Add configuration to set GOOGLE_CLOUD_PROFILER_ENABLED env
Related to gitlab-org/gitlab#409608 (closed)
This adds support for a chart configuration parameters that set
GOOGLE_CLOUD_PROFILER_ENABLED=true
env var. This env var will be used by
the Go binaries to enable Google cloud profiling.
This is already supported by the webserver https://github.com/sourcegraph/zoekt/blob/dfc14cb6a9744c038187a397528971f4012c2a01/internal/profiler/profiler.go#L12 . Right now the most important thing for us to profile is the webserver so we'll start with this but next I'll add support to the indexer for cloud profiler. I didn't bother adding it to the dynamicIndexserver container as we are going to remove that soon.
In order for us to enable this we'll still need to make a service
account with the correct permissions in GCP and then set
serviceAccount.annotations.iam.gke.io/gcp-service-account
in the
chart.