I have a Job pod with two containers, worker and sidecar. The sidecar container exposes a REST API via a service.
While the worker container is active, the sidecar container REST API functions as expected.
However, after the worker completes/exits, the sidecar is no longer reachable. I was able to determine that the network endpoints become disabled once the worker container exits.
Is it possible to configure the pod such that the network endpoints remain active as long as there are still containers running in the pod?
This is expected behaviour as of https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/#job-termination-and-cleanup.