Can I use sidecar containers with Google Cloud Run jobs?
As far as I read the documentation, it seems that sidecars can be used with Google Cloud Run services, but not with Google Cloud Run jobs.
Can I use sidecar containers with Google Cloud Run jobs?
As far as I read the documentation, it seems that sidecars can be used with Google Cloud Run services, but not with Google Cloud Run jobs.
Cloud Run jobs do not support side cars as per the runtime contract the job must exit upon completion unlike services; the best practice for jobs outlines they are to be idempotent (i.e. run once - https://cloud.google.com/run/docs/jobs-retries), as the sidecar documentation reference highlights - “If you have containers that depend on other containers, you must use healthchecks in your deployment. If you use healthchecks, Cloud Run follows the container startup order and inspects the health of each container, making sure each passes successfully before Cloud Run starts up the next container in the order.” (https://cloud.google.com/run/docs/deploying#sidecars) - as the runtime contract outlines - jobs should not serve requests (https://cloud.google.com/run/docs/container-contract)
Thank you for the explanation.
Cloud Run Jobs now support sidecars and the feature is now generally available. You can get started by following the instructions here -