{"id":16421,"date":"2016-05-15T20:44:12","date_gmt":"2016-05-15T12:44:12","guid":{"rendered":"http:\/\/vmcloud.info\/?p=16421"},"modified":"2016-05-15T20:44:12","modified_gmt":"2016-05-15T12:44:12","slug":"%e3%80%90vmcloud%e4%ba%91%e5%b9%b3%e5%8f%b0%e3%80%91%e6%8b%a5%e6%8a%b1docker%ef%bc%88%e4%ba%94%ef%bc%89volume%ef%bc%881%ef%bc%89","status":"publish","type":"post","link":"https:\/\/vmcloud.info\/?p=16421","title":{"rendered":"\u3010VMCloud\u4e91\u5e73\u53f0\u3011\u62e5\u62b1Docker\uff08\u4e94\uff09Volume\uff081\uff09"},"content":{"rendered":"<p>\u5728\u4e0a\u4e00\u7bc7\u4e2d\uff0c\u6211\u4eec\u8bb2\u5230\u4e86\u5982\u4f55\u914d\u7f6e\u591a\u4e2a\u5bb9\u5668\u5e76\u4e14\u5b9a\u5236\u5c5e\u4e8e\u81ea\u5df1\u7684\u955c\u50cf\uff0c\u4f46\u662f\u5bb9\u5668\u7684\u6570\u636e\u6027\u80fd\u4ee5\u53ca\u6301\u4e45\u5982\u4f55\u4fdd\u8bc1\u7684\uff1f\u672c\u7bc7\u5c06\u901a\u8fc7\u4ecb\u7ecdDocker Volume\u6765\u8bf4\u660e\u8fd9\u4e2a\u95ee\u9898\uff0c\u6d89\u53ca\u5230\u7684\u67b6\u6784\u5982\u4e0b\u56fe\u6240\u793a\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; float: none; padding-top: 0px; padding-left: 0px; margin-left: auto; border-left: 0px; display: block; padding-right: 0px; margin-right: auto\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb.png\" width=\"549\" height=\"407\"><\/a> <\/p>\n<p>1\u3001 \u8bf4\u5230Volume\u5b9e\u9645\u4e0a\u6709\u591a\u79cd\u65b9\u5f0f\u53ef\u4ee5\u5b9e\u73b0\uff0c\u7b2c\u4e00\u79cd\u65b9\u5f0f\u4e3a\u91c7\u7528Dockerfile\uff0c\u4f46\u8fd9\u79cd\u65b9\u5f0f\u8981\u627e\u5230\u5bf9\u5e94\u7684volume\u5b58\u653e\u5728\u4e3b\u673a\u54ea\u91cc\u6bd4\u8f83\u9ebb\u70e6\u3002\u9996\u5148\u6211\u4eec\u67e5\u627e\u6211\u4eec\u5b58\u5728\u54ea\u4e9bimages\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-1.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-1.png\" width=\"644\" height=\"116\"><\/a> <\/p>\n<p>2\u3001 \u7136\u540e\u6211\u4eec\u5199\u4e00\u4e2adockerfile\uff0c\u5e76\u5728\u5176\u4e2d\u6307\u5b9aVolume\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-2.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-2.png\" width=\"309\" height=\"267\"><\/a> <\/p>\n<p>3\u3001 \u63a5\u7740\u6211\u4eec\u4f7f\u7528docker file\u6784\u5efa\u955c\u50cf\uff08\u5173\u4e8eDockerfile\u540e\u9762\u6709\u8bb2\u5230\uff09\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-3.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-3.png\" width=\"407\" height=\"181\"><\/a> <\/p>\n<p>4\u3001 \u8fd9\u65f6\u6211\u4eec\u5c31\u521b\u5efa\u8d77\u4e00\u4e2a\u5e26\u6709Volume\u7684\u57fa\u7840\u955c\u50cf\uff0c\u800c\u57fa\u4e8e\u8fd9\u4e2a\u57fa\u7840\u955c\u50cf\u6240\u521b\u5efa\u7684\u5bb9\u5668\u90fd\u4f1a\u6709\u4e00\u4e2a\/VMCTest\u7684\u6302\u8f7d\u70b9\uff0c\u6211\u4eec\u53ef\u4ee5\u6d4b\u8bd5\u521b\u5efa\u4e00\u4e2a\u5bb9\u5668\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-4.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-4.png\" width=\"614\" height=\"65\"><\/a> <\/p>\n<p>5\u3001 \u6211\u4eec\u6765\u770b\u4e0b\u662f\u5426\u5b58\u5728\u4e00\u4e2a\/VMCTest\u6302\u8f7d\u70b9\uff0c\u6211\u4eec\u521b\u5efa\u4e00\u4e2a\u6587\u4ef6\u4ee5\u4f5c\u6d4b\u8bd5\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-5.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-5.png\" width=\"494\" height=\"113\"><\/a> <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-6.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-6.png\" width=\"313\" height=\"109\"><\/a> <\/p>\n<p>6\u3001 \u90a3\u4e48\u8fd9\u4e2aVMCTest\u7a76\u7adf\u5b58\u5728\u54ea\u91cc\u7684\u5462\uff1f\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u6765\u67e5\u770b\u5b9e\u9645\u4f4d\u7f6e: <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-7.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-7.png\" width=\"644\" height=\"88\"><\/a> <\/p>\n<p>7\u3001\u53ef\u4ee5\u770b\u5230\u5b9e\u9645\u7684\u6620\u5c04\u4f4d\u7f6e\uff0c\u6211\u4eec\u53ef\u4ee5\u8fdb\u5165\u5230\u8be5\u8def\u5f84\u770b\u4e0b\uff0c\u521a\u521a\u521b\u5efa\u7684\u6d4b\u8bd5\u6587\u4ef6\u5728\u4e0d\u5728\uff1a <\/p>\n<p><a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-8.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; margin: 0px; display: inline; padding-right: 0px\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-8.png\" width=\"644\" height=\"106\"><\/a> <\/p>\n<p>8\u3001OK\uff0c\u5173\u4e8e\u6570\u636e\u5377\u7684\u7b2c\u4e00\u79cd\u7528\u6cd5\uff0c\u6211\u4eec\u5c31\u4ecb\u7ecd\u5230\u8fd9\u91cc\uff0c\u4e0b\u4e00\u7bc7\u6211\u4eec\u5c06\u4ecb\u7ecd\u53e6\u5916\u4e00\u79cd\u66f4\u52a0\u66b4\u529b\u7684\u6302\u8f7d\u65b9\u5f0f\u3002         <\/p>\n<hr>\n<p> <a href=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image-9.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; float: none; padding-top: 0px; padding-left: 0px; margin-left: auto; border-left: 0px; display: block; padding-right: 0px; margin-right: auto\" border=\"0\" alt=\"image\" src=\"https:\/\/vmcloud.info\/wp-content\/uploads\/2016\/05\/image_thumb-9.png\" width=\"537\" height=\"351\"><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5728\u4e0a\u4e00\u7bc7\u4e2d\uff0c\u6211\u4eec\u8bb2\u5230\u4e86\u5982\u4f55\u914d\u7f6e\u591a\u4e2a\u5bb9\u5668\u5e76\u4e14\u5b9a\u5236\u5c5e\u4e8e\u81ea\u5df1\u7684\u955c\u50cf\uff0c\u4f46\u662f\u5bb9\u5668\u7684\u6570\u636e\u6027\u80fd\u4ee5\u53ca\u6301\u4e45\u5982\u4f55\u4fdd\u8bc1\u7684\uff1f\u672c\u7bc7\u5c06\u901a\u8fc7\u4ecb\u7ecdDocker Volume\u6765\u8bf4\u660e\u8fd9\u4e2a\u95ee\u9898\uff0c\u6d89\u53ca\u5230\u7684\u67b6\u6784\u5982\u4e0b\u56fe\u6240\u793a\uff1a 1\u3001 \u8bf4\u5230Volume\u5b9e\u9645\u4e0a\u6709\u591a\u79cd\u65b9\u5f0f\u53ef\u4ee5\u5b9e\u73b0\uff0c\u7b2c\u4e00\u79cd\u65b9\u5f0f\u4e3a\u91c7\u7528Dockerfile\uff0c\u4f46\u8fd9\u79cd\u65b9\u5f0f\u8981\u627e\u5230\u5bf9\u5e94\u7684volume\u5b58\u653e\u5728\u4e3b\u673a\u54ea\u91cc\u6bd4\u8f83\u9ebb\u70e6\u3002\u9996\u5148\u6211\u4eec\u67e5\u627e\u6211\u2026\u2026<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[231],"tags":[],"class_list":["post-16421","post","type-post","status-publish","format-standard","hentry","category-231"],"_links":{"self":[{"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/posts\/16421","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/vmcloud.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=16421"}],"version-history":[{"count":1,"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/posts\/16421\/revisions"}],"predecessor-version":[{"id":16431,"href":"https:\/\/vmcloud.info\/index.php?rest_route=\/wp\/v2\/posts\/16421\/revisions\/16431"}],"wp:attachment":[{"href":"https:\/\/vmcloud.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=16421"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/vmcloud.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=16421"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/vmcloud.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=16421"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}