@@ -4,8 +4,8 @@ content_type: concept
4
4
feature :
5
5
title : Secret 和配置管理
6
6
description : >
7
- 部署和更新 Secret 和应用程序的配置而不必重新构建容器镜像,且
8
- 不必将软件堆栈配置中的秘密信息暴露出来 。
7
+ 部署和更新 Secret 和应用程序的配置而不必重新构建容器镜像,
8
+ 且不必将软件堆栈配置中的秘密信息暴露出来 。
9
9
weight : 30
10
10
---
11
11
<!--
@@ -266,10 +266,9 @@ values in the `data` field; for example:
266
266
例如:
267
267
268
268
``` yaml
269
- # Please edit the object below. Lines beginning with a '#' will be ignored,
270
- # and an empty file will abort the edit. If an error occurs while saving this file, it will be
271
- # reopened with the relevant failures.
272
- #
269
+ # 请编辑以下对象。以 `#` 开头的几行将被忽略,
270
+ # 且空文件将放弃编辑。如果保存此文件时出错,
271
+ # 则重新打开此文件时也会有相关故障。
273
272
apiVersion : v1
274
273
data :
275
274
username : YWRtaW4=
@@ -915,7 +914,7 @@ You cannot use ConfigMaps or Secrets with
915
914
-->
916
915
### 在静态 Pod 中使用 Secret {#restriction-static-pod}
917
916
918
- 你不可以在{{< glossary_tooltip text="静态 Pod" term_id="static-pod" >}}.
917
+ 你不可以在{{< glossary_tooltip text="静态 Pod" term_id="static-pod" >}}
919
918
中使用 ConfigMap 或 Secret。
920
919
921
920
<!--
@@ -1113,7 +1112,7 @@ secret "test-db-secret" created
1113
1112
Special characters such as `$`, `\`, `*`, `=`, and `!` will be interpreted by your [shell](https://en.wikipedia.org/wiki/Shell_(computing)) and require escaping.
1114
1113
-->
1115
1114
特殊字符(例如 ` $ ` 、` \ ` 、` * ` 、` = ` 和 ` ! ` )会被你的
1116
- [ Shell] ( https://zh.wikipedia.org/wiki/Shell_(computing) ) 解释,因此需要转义。
1115
+ [ Shell] ( https://zh.wikipedia.org/wiki/%E6%AE%BC%E5%B1%A4 ) 解释,因此需要转义。
1117
1116
1118
1117
<!--
1119
1118
In most shells, the easiest way to escape the password is to surround it with single quotes (`'`).
@@ -1563,7 +1562,7 @@ store the credentials for accessing a container image registry:
1563
1562
-->
1564
1563
# ## Docker 配置 Secret {#docker-config-secrets}
1565
1564
1566
- 你可以使用下面两种 `type` 值之一来创建 Secret,用以存放用于访问容器鏡像倉庫的凭据 :
1565
+ 你可以使用下面两种 `type` 值之一来创建 Secret,用以存放用于访问容器镜像仓库的凭据 :
1567
1566
1568
1567
- ` kubernetes.io/dockercfg`
1569
1568
- ` kubernetes.io/dockerconfigjson`
@@ -1631,7 +1630,7 @@ to create a Secret for accessing a container registry, you can do:
1631
1630
不过,API 服务器不会检查 JSON 数据本身是否是一个合法的 Docker 配置文件内容。
1632
1631
1633
1632
当你没有 Docker 配置文件,或者你想使用 `kubectl` 创建一个 Secret
1634
- 来访问容器倉庫时 ,你可以这样做:
1633
+ 来访问容器仓库时 ,你可以这样做:
1635
1634
1636
1635
` ` ` shell
1637
1636
kubectl create secret docker-registry secret-tiger-docker \
0 commit comments