R
RunPod2w ago
Marvin

Pod overwrites my project code in "Volume Mount Path"

I run my container on pod where all my code lives in "/workspace/project/". When I set "Volume Mount Path" in my pod template to be "/workspace/project/" it overwrites my project code completely. It seems that volume mount happens after container is up and running, which removes everything in my project folder. Is there a workaround for this? (I'm not using a network volume btw)
Solution:
just put files outside of /workspace then sync or copy
Jump to solution
8 Replies
nerdylive
nerdylive2w ago
so your project should be in /workspace/project/project isnt it?
Marvin
MarvinOP2w ago
I tried mounting to "/workspace" or "/workspace/". Once the pod is up and running, it will leave me an empty workspace folder. (My project code is in /workspace/project/". These are the files come docker image) Am I supposed to load project file to somewhere else then copy and paste to workspace after mounting finished? :think360:
Madiator2011
Madiator20112w ago
yup cause volume ounts at /workspace
Marvin
MarvinOP2w ago
Thanks! Is there a good link that I could learn about network volumes for persistant storage? downloading everything (project code, data) each time i run the pod is time consuming and I could't find any useful youtube tut vids.
Solution
Madiator2011
Madiator20112w ago
just put files outside of /workspace then sync or copy
Marvin
MarvinOP2w ago
I'm currently assuming that if I created a network volume, the things stored in mounted path are also stored in the persistant storage, just like mouting path in docker conatiners.
Madiator2011
Madiator20112w ago
yes
Marvin
MarvinOP2w ago
Thanks!

Did you find this page helpful?