I have a docker image on Google Container engine with volumes attached to it. Is there a way to get files from my local filesytem to the attached volumes?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
I took the following steps to achieve the above:
- Create the directory where the volume should be mounted in the instance.
- Format the volume and mount it on the directory created above.
- Give the directory write permissions(chmod a+w )
- Create the fstab entriy for mounting the volume.
You can then use gcloud compute copy-files to copy files from your local filesystem to the volume, which is mounted on a directory on the instance.