Jenkins on Kubernetes

#1

I am setting up Jenkins on kubernetes using the kubernetes plugin(ephemeral build pods/containers) and am looking for a specific design/solution for cacheing build artifacts. Specifically if I am doing a maven build, I want to be able to cache the maven dependencies so that each new build does not have to fetch a new set of artifacts. So I need a cache(local repository) I can share between builds. I am wondering what kind of solutions people are using for an ephemeral cache?
Using a Persistent Volume seems to heavy weight as cache does not necessarily need to be around forever and does not need to be shared between nodes. Perhaps a hostpath volume makes more sense?
Suggestions?

0 Likes