Skip to content

support multiple cloudsql_instances in cloudrun svc

Problem

When multiple cloudsql_instances are configured, we get an error (From example job https://gitlab.com/gitlab-com/gl-infra/platform/runway/deployments/dx-observer/-/jobs/11462212780#L452)

│ Error: Error updating Service "projects/gitlab-[MASKED]-staging/locations/us-east1/services/dx-observer": googleapi: Error 400: template.containers: Containers [1, 2] have duplicate container names

that's because we specify a static name in the container config https://gitlab.com/gitlab-com/gl-infra/platform/runway/runwayctl/-/blob/main/reconciler/kind/RunwayService/main.tf?ref_type=heads#L256-284

Acceptance criteria

Service owners can specify multiple cloudsql_instances without errors

Edited by Dan Ryan