File tree Expand file tree Collapse file tree 2 files changed +41
-0
lines changed
docs/tasks/configure-pod-container Expand file tree Collapse file tree 2 files changed +41
-0
lines changed Original file line number Diff line number Diff line change @@ -387,6 +387,25 @@ You can now close the shell to your Node.
387
387
-->
388
388
你现在可以关闭连接到节点的 Shell。
389
389
390
+ <!--
391
+ ## Mounting the same persistentVolume in two places
392
+ -->
393
+
394
+ ## 在两个地方挂载相同的 persistentVolume
395
+
396
+ {{< codenew file="pods/storage/pv-duplicate.yaml" >}}
397
+
398
+ <!--
399
+ You can perform 2 volume mounts on your nginx container:
400
+
401
+ `/usr/share/nginx/html` for the static website
402
+ `/etc/nginx/nginx.conf` for the default config
403
+ -->
404
+ 你可以在 nginx 容器上执行两个卷挂载:
405
+
406
+ ` /usr/share/nginx/html ` 用于静态网站
407
+ ` /etc/nginx/nginx.conf ` 作为默认配置
408
+
390
409
<!-- discussion -->
391
410
392
411
<!--
Original file line number Diff line number Diff line change
1
+
2
+ apiVersion : v1
3
+ kind : Pod
4
+ metadata :
5
+ name : test
6
+ spec :
7
+ containers :
8
+ - name : test
9
+ image : nginx
10
+ volumeMounts :
11
+ # 网站数据挂载
12
+ - name : config
13
+ mountPath : /usr/share/nginx/html
14
+ subPath : html
15
+ # Nginx 配置挂载
16
+ - name : config
17
+ mountPath : /etc/nginx/nginx.conf
18
+ subPath : nginx.conf
19
+ volumes :
20
+ - name : config
21
+ persistentVolumeClaim :
22
+ claimName : test-nfs-claim
You can’t perform that action at this time.
0 commit comments