Skip to content

Commit 0e17dd9

Browse files
authored
sync yaml py Dockerfile json with /en (#19882)
1 parent 05d962d commit 0e17dd9

29 files changed

+926
-936
lines changed
Lines changed: 69 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,69 @@
1-
# This is an example of how to setup cloud-controller-manger as a Daemonset in your cluster.
2-
# It assumes that your masters can run pods and has the role node-role.kubernetes.io/master
3-
# Note that this Daemonset will not work straight out of the box for your cloud, this is
4-
# meant to be a guideline.
5-
6-
---
7-
apiVersion: v1
8-
kind: ServiceAccount
9-
metadata:
10-
name: cloud-controller-manager
11-
namespace: kube-system
12-
---
13-
apiVersion: rbac.authorization.k8s.io/v1
14-
kind: ClusterRoleBinding
15-
metadata:
16-
name: system:cloud-controller-manager
17-
roleRef:
18-
apiGroup: rbac.authorization.k8s.io
19-
kind: ClusterRole
20-
name: cluster-admin
21-
subjects:
22-
- kind: ServiceAccount
23-
name: cloud-controller-manager
24-
namespace: kube-system
25-
---
26-
apiVersion: apps/v1
27-
kind: DaemonSet
28-
metadata:
29-
labels:
30-
k8s-app: cloud-controller-manager
31-
name: cloud-controller-manager
32-
namespace: kube-system
33-
spec:
34-
selector:
35-
matchLabels:
36-
k8s-app: cloud-controller-manager
37-
template:
38-
metadata:
39-
labels:
40-
k8s-app: cloud-controller-manager
41-
spec:
42-
serviceAccountName: cloud-controller-manager
43-
containers:
44-
- name: cloud-controller-manager
45-
# for in-tree providers we use k8s.gcr.io/cloud-controller-manager
46-
# this can be replaced with any other image for out-of-tree providers
47-
image: k8s.gcr.io/cloud-controller-manager:v1.8.0
48-
command:
49-
- /usr/local/bin/cloud-controller-manager
50-
- --cloud-provider=[YOUR_CLOUD_PROVIDER] # Add your own cloud provider here!
51-
- --leader-elect=true
52-
- --use-service-account-credentials
53-
# these flags will vary for every cloud provider
54-
- --allocate-node-cidrs=true
55-
- --configure-cloud-routes=true
56-
- --cluster-cidr=172.17.0.0/16
57-
tolerations:
58-
# this is required so CCM can bootstrap itself
59-
- key: node.cloudprovider.kubernetes.io/uninitialized
60-
value: "true"
61-
effect: NoSchedule
62-
# this is to have the daemonset runnable on master nodes
63-
# the taint may vary depending on your cluster setup
64-
- key: node-role.kubernetes.io/master
65-
effect: NoSchedule
66-
# this is to restrict CCM to only run on master nodes
67-
# the node selector may vary depending on your cluster setup
68-
nodeSelector:
69-
node-role.kubernetes.io/master: ""
1+
# This is an example of how to setup cloud-controller-manger as a Daemonset in your cluster.
2+
# It assumes that your masters can run pods and has the role node-role.kubernetes.io/master
3+
# Note that this Daemonset will not work straight out of the box for your cloud, this is
4+
# meant to be a guideline.
5+
6+
---
7+
apiVersion: v1
8+
kind: ServiceAccount
9+
metadata:
10+
name: cloud-controller-manager
11+
namespace: kube-system
12+
---
13+
apiVersion: rbac.authorization.k8s.io/v1
14+
kind: ClusterRoleBinding
15+
metadata:
16+
name: system:cloud-controller-manager
17+
roleRef:
18+
apiGroup: rbac.authorization.k8s.io
19+
kind: ClusterRole
20+
name: cluster-admin
21+
subjects:
22+
- kind: ServiceAccount
23+
name: cloud-controller-manager
24+
namespace: kube-system
25+
---
26+
apiVersion: apps/v1
27+
kind: DaemonSet
28+
metadata:
29+
labels:
30+
k8s-app: cloud-controller-manager
31+
name: cloud-controller-manager
32+
namespace: kube-system
33+
spec:
34+
selector:
35+
matchLabels:
36+
k8s-app: cloud-controller-manager
37+
template:
38+
metadata:
39+
labels:
40+
k8s-app: cloud-controller-manager
41+
spec:
42+
serviceAccountName: cloud-controller-manager
43+
containers:
44+
- name: cloud-controller-manager
45+
# for in-tree providers we use k8s.gcr.io/cloud-controller-manager
46+
# this can be replaced with any other image for out-of-tree providers
47+
image: k8s.gcr.io/cloud-controller-manager:v1.8.0
48+
command:
49+
- /usr/local/bin/cloud-controller-manager
50+
- --cloud-provider=[YOUR_CLOUD_PROVIDER] # Add your own cloud provider here!
51+
- --leader-elect=true
52+
- --use-service-account-credentials
53+
# these flags will vary for every cloud provider
54+
- --allocate-node-cidrs=true
55+
- --configure-cloud-routes=true
56+
- --cluster-cidr=172.17.0.0/16
57+
tolerations:
58+
# this is required so CCM can bootstrap itself
59+
- key: node.cloudprovider.kubernetes.io/uninitialized
60+
value: "true"
61+
effect: NoSchedule
62+
# this is to have the daemonset runnable on master nodes
63+
# the taint may vary depending on your cluster setup
64+
- key: node-role.kubernetes.io/master
65+
effect: NoSchedule
66+
# this is to restrict CCM to only run on master nodes
67+
# the node selector may vary depending on your cluster setup
68+
nodeSelector:
69+
node-role.kubernetes.io/master: ""
Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,33 @@
1-
apiVersion: apps/v1
2-
kind: Deployment
3-
metadata:
4-
name: dns-autoscaler
5-
namespace: kube-system
6-
labels:
7-
k8s-app: dns-autoscaler
8-
spec:
9-
selector:
10-
matchLabels:
11-
k8s-app: dns-autoscaler
12-
template:
13-
metadata:
14-
labels:
15-
k8s-app: dns-autoscaler
16-
spec:
17-
containers:
18-
- name: autoscaler
19-
image: k8s.gcr.io/cluster-proportional-autoscaler-amd64:1.6.0
20-
resources:
21-
requests:
22-
cpu: 20m
23-
memory: 10Mi
24-
command:
25-
- /cluster-proportional-autoscaler
26-
- --namespace=kube-system
27-
- --configmap=dns-autoscaler
28-
- --target=<SCALE_TARGET>
29-
# When cluster is using large nodes(with more cores), "coresPerReplica" should dominate.
30-
# If using small nodes, "nodesPerReplica" should dominate.
31-
- --default-params={"linear":{"coresPerReplica":256,"nodesPerReplica":16,"min":1}}
32-
- --logtostderr=true
33-
- --v=2
1+
apiVersion: apps/v1
2+
kind: Deployment
3+
metadata:
4+
name: dns-autoscaler
5+
namespace: kube-system
6+
labels:
7+
k8s-app: dns-autoscaler
8+
spec:
9+
selector:
10+
matchLabels:
11+
k8s-app: dns-autoscaler
12+
template:
13+
metadata:
14+
labels:
15+
k8s-app: dns-autoscaler
16+
spec:
17+
containers:
18+
- name: autoscaler
19+
image: k8s.gcr.io/cluster-proportional-autoscaler-amd64:1.6.0
20+
resources:
21+
requests:
22+
cpu: 20m
23+
memory: 10Mi
24+
command:
25+
- /cluster-proportional-autoscaler
26+
- --namespace=kube-system
27+
- --configmap=dns-autoscaler
28+
- --target=<SCALE_TARGET>
29+
# When cluster is using large nodes(with more cores), "coresPerReplica" should dominate.
30+
# If using small nodes, "nodesPerReplica" should dominate.
31+
- --default-params={"linear":{"coresPerReplica":256,"nodesPerReplica":16,"min":1}}
32+
- --logtostderr=true
33+
- --v=2
Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
apiVersion: v1
2-
kind: Pod
3-
metadata:
4-
name: dnsutils
5-
namespace: default
6-
spec:
7-
containers:
8-
- name: dnsutils
9-
image: gcr.io/kubernetes-e2e-test-images/dnsutils:1.3
10-
command:
11-
- sleep
12-
- "3600"
13-
imagePullPolicy: IfNotPresent
14-
restartPolicy: Always
1+
apiVersion: v1
2+
kind: Pod
3+
metadata:
4+
name: dnsutils
5+
namespace: default
6+
spec:
7+
containers:
8+
- name: dnsutils
9+
image: gcr.io/kubernetes-e2e-test-images/dnsutils:1.3
10+
command:
11+
- sleep
12+
- "3600"
13+
imagePullPolicy: IfNotPresent
14+
restartPolicy: Always

content/zh/examples/admin/namespace-dev.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"kind": "Namespace",
32
"apiVersion": "v1",
3+
"kind": "Namespace",
44
"metadata": {
55
"name": "development",
66
"labels": {

content/zh/examples/admin/namespace-prod.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"kind": "Namespace",
32
"apiVersion": "v1",
3+
"kind": "Namespace",
44
"metadata": {
55
"name": "production",
66
"labels": {

content/zh/examples/admin/resource/quota-mem-cpu-pod-2.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ spec:
99
resources:
1010
limits:
1111
memory: "1Gi"
12-
cpu: "800m"
12+
cpu: "800m"
1313
requests:
1414
memory: "700Mi"
1515
cpu: "400m"
16-
16+

content/zh/examples/admin/resource/quota-mem-cpu-pod.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ spec:
99
resources:
1010
limits:
1111
memory: "800Mi"
12-
cpu: "800m"
12+
cpu: "800m"
1313
requests:
1414
memory: "600Mi"
1515
cpu: "400m"
16-
16+

0 commit comments

Comments
 (0)