Creating additional volumes for sidecar containers

Our setup:

  • SonarQube v9.9.0
  • Using Helm chart to deploy in Google Kubernetes Engine (GKE)
  • Google Cloud Platform (GCP) Cloud SQL with cloud sql auth proxy

What I’m trying to do:

Deploy the cloud-sql auth proxy as a sidecar using the extraContainers option in the values.yml

The problem

The cloud-sql auth proxy container requires a volume (we typically just use an emptyDir volume) and I am not able to create the necessary volume.

What I’ve tried:

I attempted to have the volume created using the persistence.volumes option but this appears not to work as I thought.

  • I did try it with both persistence.enabled=True and also persistence.enabled=False

Currently I’m having some success creating the cloud-sql auth proxy container as it’s own pod under the same namespace and connecting to the db via <IP address>.<namespace>.pod.cluster.local, but this is less ideal than having the cloud sql proxy accessible in the same pod.

Hello @Jacob_Williams thanks a lot for taking the time to participate in the community.

We have other users reporting the same needs, based on that we have an ongoing PR here that will provide the feature.

Allowing to add extra volume definition, that you will be able to mount with the extraContainer.

Would this PR help you with solving the issue?

Nonetheless after being merged, it will be officially released with the new SonarQube 10.0.


1 Like

Hi Jeremy, thanks for getting back to me. This is exactly the feature I had in mind and should solve my use case. I’ll be keeping an eye on that PR and awaiting the 10.0 release. Thank you!


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.