I installed minikube
and started Jenkins
inside a pod
. I am able to create a new job and execute it inside a dynamically created maven container
. However. I have a folder in my host
machine which is a Mac
based and I need that folder inside this dynamically created pod
when the job is started. How can I achieve that?
Option 1.
https://kubernetes.io/docs/setup/minikube/#interacting-with-your-cluster
configure kubectl on your MAC, then use kubectl cp <hostdir> <podname>:<dir>
Option 2.
use the Host path option for POD, like this post
Maybe the easiest solution is to push that folder as git repo ( if it is not large ) to either github or your private git server , and then clone it as a first step in your jenkins job.