This feels like a complex issue to solve with imagination only. If you have a good env and perfect/untouched k8s yaml. Delete the deployment, make sure the volumes are erased. And start again from scratch.
See this? This is a result of mixing environments and configs. You were testing something. You didn’t clean up the Paths/directories correctly. And now this instance expects the same context as before.
There is no way for k8s to work with “localhost”. It is possible, but instances in other pods will have a hard time knowing what you want to do.