Shared volume between pods

Hello,

To optimise the ressources needed by my application (pod) I would like to use shared volume and if it’s possible with a deletion rule.

When a container start I need to build an application cache. It’s done in the docker entrypoint. This build need lot of CPU to be build fast, if it’s not too fast it will trigger auto scaling up based on CPU usage. I can change setting about auto-scaling but I will lose some “reactivity” when it’s needed.

So for that I’m thinking about having a 2 lifecycle applications that is run on each deployment to build the application cache and put it on a shared volume. The first one will have the responsability to build the cache and the second one, at the end of deployment to remove existing previous ones.

All my pods of this application will use the shared volume as read only to get access to the cache and don’t have the need to generate it on each container start. With this it will be possible for me to reduce the resources allowed to my container.

Do you have advice on how to do it with Qovery ?

Thanks a lot