From 214bd5d85e63af44ab2a4b6f49ff7c5b3298384c Mon Sep 17 00:00:00 2001 From: Jinhua Tan <312841925@qq.com> Date: Sun, 23 Jun 2019 22:37:54 +0800 Subject: [PATCH] zh sync to en: move user-guide to reference/kubectl (#14843) --- .../kubectl}/docker-cli-to-kubectl.md | 0 .../kubectl}/jsonpath.md | 0 .../kubectl}/kubectl-overview.md | 0 .../docs/user-guide/bad-nginx-deployment.yaml | 16 ------- content/zh/docs/user-guide/curlpod.yaml | 25 ---------- content/zh/docs/user-guide/deployment.yaml | 21 -------- content/zh/docs/user-guide/ingress.yaml | 9 ---- content/zh/docs/user-guide/job.yaml | 15 ------ content/zh/docs/user-guide/multi-pod.yaml | 48 ------------------- .../docs/user-guide/new-nginx-deployment.yaml | 16 ------- content/zh/docs/user-guide/nginx-app.yaml | 29 ----------- .../zh/docs/user-guide/nginx-deployment.yaml | 16 ------- .../user-guide/nginx-init-containers.yaml | 29 ----------- .../nginx-lifecycle-deployment.yaml | 20 -------- .../user-guide/nginx-probe-deployment.yaml | 22 --------- .../zh/docs/user-guide/nginx-secure-app.yaml | 46 ------------------ content/zh/docs/user-guide/nginx-svc.yaml | 12 ----- content/zh/docs/user-guide/pod-w-message.yaml | 10 ---- content/zh/docs/user-guide/pod.yaml | 12 ----- .../zh/docs/user-guide/redis-deployment.yaml | 24 ---------- .../user-guide/redis-resource-deployment.yaml | 27 ----------- .../user-guide/redis-secret-deployment.yaml | 27 ----------- content/zh/docs/user-guide/run-my-nginx.yaml | 20 -------- 23 files changed, 444 deletions(-) rename content/zh/docs/{user-guide => reference/kubectl}/docker-cli-to-kubectl.md (100%) rename content/zh/docs/{user-guide => reference/kubectl}/jsonpath.md (100%) rename content/zh/docs/{user-guide => reference/kubectl}/kubectl-overview.md (100%) delete mode 100644 content/zh/docs/user-guide/bad-nginx-deployment.yaml delete mode 100644 content/zh/docs/user-guide/curlpod.yaml delete mode 100644 content/zh/docs/user-guide/deployment.yaml delete mode 100644 content/zh/docs/user-guide/ingress.yaml delete mode 100644 content/zh/docs/user-guide/job.yaml delete mode 100644 content/zh/docs/user-guide/multi-pod.yaml delete mode 100644 content/zh/docs/user-guide/new-nginx-deployment.yaml delete mode 100644 content/zh/docs/user-guide/nginx-app.yaml delete mode 100644 content/zh/docs/user-guide/nginx-deployment.yaml delete mode 100644 content/zh/docs/user-guide/nginx-init-containers.yaml delete mode 100644 content/zh/docs/user-guide/nginx-lifecycle-deployment.yaml delete mode 100644 content/zh/docs/user-guide/nginx-probe-deployment.yaml delete mode 100644 content/zh/docs/user-guide/nginx-secure-app.yaml delete mode 100644 content/zh/docs/user-guide/nginx-svc.yaml delete mode 100644 content/zh/docs/user-guide/pod-w-message.yaml delete mode 100644 content/zh/docs/user-guide/pod.yaml delete mode 100644 content/zh/docs/user-guide/redis-deployment.yaml delete mode 100644 content/zh/docs/user-guide/redis-resource-deployment.yaml delete mode 100644 content/zh/docs/user-guide/redis-secret-deployment.yaml delete mode 100644 content/zh/docs/user-guide/run-my-nginx.yaml diff --git a/content/zh/docs/user-guide/docker-cli-to-kubectl.md b/content/zh/docs/reference/kubectl/docker-cli-to-kubectl.md similarity index 100% rename from content/zh/docs/user-guide/docker-cli-to-kubectl.md rename to content/zh/docs/reference/kubectl/docker-cli-to-kubectl.md diff --git a/content/zh/docs/user-guide/jsonpath.md b/content/zh/docs/reference/kubectl/jsonpath.md similarity index 100% rename from content/zh/docs/user-guide/jsonpath.md rename to content/zh/docs/reference/kubectl/jsonpath.md diff --git a/content/zh/docs/user-guide/kubectl-overview.md b/content/zh/docs/reference/kubectl/kubectl-overview.md similarity index 100% rename from content/zh/docs/user-guide/kubectl-overview.md rename to content/zh/docs/reference/kubectl/kubectl-overview.md diff --git a/content/zh/docs/user-guide/bad-nginx-deployment.yaml b/content/zh/docs/user-guide/bad-nginx-deployment.yaml deleted file mode 100644 index e93cf309b4..0000000000 --- a/content/zh/docs/user-guide/bad-nginx-deployment.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx-deployment -spec: - replicas: 3 - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx:1.91 - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/curlpod.yaml b/content/zh/docs/user-guide/curlpod.yaml deleted file mode 100644 index 0741a58e7f..0000000000 --- a/content/zh/docs/user-guide/curlpod.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: curl-deployment -spec: - replicas: 1 - template: - metadata: - labels: - app: curlpod - spec: - volumes: - - name: secret-volume - secret: - secretName: nginxsecret - containers: - - name: curlpod - command: - - sh - - -c - - while true; do sleep 1; done - image: radial/busyboxplus:curl - volumeMounts: - - mountPath: /etc/nginx/ssl - name: secret-volume diff --git a/content/zh/docs/user-guide/deployment.yaml b/content/zh/docs/user-guide/deployment.yaml deleted file mode 100644 index 8cdf1692ef..0000000000 --- a/content/zh/docs/user-guide/deployment.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx-deployment - labels: - name: nginx-deployment -spec: - replicas: 3 - selector: - matchLabels: - name: nginx - template: - metadata: - labels: - name: nginx - spec: - containers: - - name: nginx - image: nginx - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/ingress.yaml b/content/zh/docs/user-guide/ingress.yaml deleted file mode 100644 index 56a0d5138f..0000000000 --- a/content/zh/docs/user-guide/ingress.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: networking.k8s.io/v1beta1 -kind: Ingress -metadata: - name: test-ingress -spec: - backend: - serviceName: testsvc - servicePort: 80 - diff --git a/content/zh/docs/user-guide/job.yaml b/content/zh/docs/user-guide/job.yaml deleted file mode 100644 index ece4512a8a..0000000000 --- a/content/zh/docs/user-guide/job.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: batch/v1 -kind: Job -metadata: - name: pi -spec: - template: - metadata: - name: pi - spec: - containers: - - name: pi - image: perl - command: ["perl", "-Mbignum=bpi", "-wle", "print bpi(2000)"] - restartPolicy: Never - diff --git a/content/zh/docs/user-guide/multi-pod.yaml b/content/zh/docs/user-guide/multi-pod.yaml deleted file mode 100644 index 2ace060d89..0000000000 --- a/content/zh/docs/user-guide/multi-pod.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - labels: - name: redis - redis-sentinel: "true" - role: master - name: redis-master -spec: - containers: - - name: master - image: kubernetes/redis:v1 - env: - - name: MASTER - value: "true" - ports: - - containerPort: 6379 - resources: - limits: - cpu: "0.5" - volumeMounts: - - mountPath: /redis-master-data - name: data - - name: sentinel - image: kubernetes/redis:v1 - env: - - name: SENTINEL - value: "true" - ports: - - containerPort: 26379 - volumes: - - name: data - emptyDir: {} ---- -apiVersion: v1 -kind: Pod -metadata: - labels: - name: redis-proxy - role: proxy - name: redis-proxy -spec: - containers: - - name: proxy - image: kubernetes/redis-proxy:v1 - ports: - - containerPort: 6379 - name: api diff --git a/content/zh/docs/user-guide/new-nginx-deployment.yaml b/content/zh/docs/user-guide/new-nginx-deployment.yaml deleted file mode 100644 index 67bb9fd10f..0000000000 --- a/content/zh/docs/user-guide/new-nginx-deployment.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx-deployment -spec: - replicas: 3 - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx:1.9.1 - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/nginx-app.yaml b/content/zh/docs/user-guide/nginx-app.yaml deleted file mode 100644 index bc7e095646..0000000000 --- a/content/zh/docs/user-guide/nginx-app.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: my-nginx-svc - labels: - app: nginx -spec: - type: LoadBalancer - ports: - - port: 80 - selector: - app: nginx ---- -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: my-nginx -spec: - replicas: 3 - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx:1.7.9 - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/nginx-deployment.yaml b/content/zh/docs/user-guide/nginx-deployment.yaml deleted file mode 100644 index 2aabf5e7b1..0000000000 --- a/content/zh/docs/user-guide/nginx-deployment.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx-deployment -spec: - replicas: 3 - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx:1.7.9 - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/nginx-init-containers.yaml b/content/zh/docs/user-guide/nginx-init-containers.yaml deleted file mode 100644 index fdfde0619a..0000000000 --- a/content/zh/docs/user-guide/nginx-init-containers.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: nginx -spec: - containers: - - name: nginx - image: nginx - ports: - - containerPort: 80 - volumeMounts: - - name: workdir - mountPath: /usr/share/nginx/html - # These containers are run during pod initialization - initContainers: - - name: install - image: busybox - command: - - wget - - "-O" - - "/work-dir/index.html" - - http://kubernetes.io/index.html - volumeMounts: - - name: workdir - mountPath: "/work-dir" - dnsPolicy: Default - volumes: - - name: workdir - emptyDir: {} diff --git a/content/zh/docs/user-guide/nginx-lifecycle-deployment.yaml b/content/zh/docs/user-guide/nginx-lifecycle-deployment.yaml deleted file mode 100644 index 52bbbe23d7..0000000000 --- a/content/zh/docs/user-guide/nginx-lifecycle-deployment.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx -spec: - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx - ports: - - containerPort: 80 - lifecycle: - preStop: - exec: - # SIGTERM triggers a quick exit; gracefully terminate instead - command: ["/usr/sbin/nginx","-s","quit"] diff --git a/content/zh/docs/user-guide/nginx-probe-deployment.yaml b/content/zh/docs/user-guide/nginx-probe-deployment.yaml deleted file mode 100644 index d1d849efef..0000000000 --- a/content/zh/docs/user-guide/nginx-probe-deployment.yaml +++ /dev/null @@ -1,22 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: nginx -spec: - template: - metadata: - labels: - app: nginx - spec: - containers: - - name: nginx - image: nginx - ports: - - containerPort: 80 - livenessProbe: - httpGet: - # Path to probe; should be cheap, but representative of typical behavior - path: /index.html - port: 80 - initialDelaySeconds: 30 - timeoutSeconds: 1 diff --git a/content/zh/docs/user-guide/nginx-secure-app.yaml b/content/zh/docs/user-guide/nginx-secure-app.yaml deleted file mode 100644 index ec180a18df..0000000000 --- a/content/zh/docs/user-guide/nginx-secure-app.yaml +++ /dev/null @@ -1,46 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: my-nginx - labels: - run: my-nginx -spec: - type: NodePort - ports: - - port: 8080 - targetPort: 80 - protocol: TCP - name: http - - port: 443 - protocol: TCP - name: https - selector: - run: my-nginx ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - name: my-nginx -spec: - selector: - matchLabels: - run: my-nginx - replicas: 1 - template: - metadata: - labels: - run: my-nginx - spec: - volumes: - - name: secret-volume - secret: - secretName: nginxsecret - containers: - - name: nginxhttps - image: bprashanth/nginxhttps:1.0 - ports: - - containerPort: 443 - - containerPort: 80 - volumeMounts: - - mountPath: /etc/nginx/ssl - name: secret-volume diff --git a/content/zh/docs/user-guide/nginx-svc.yaml b/content/zh/docs/user-guide/nginx-svc.yaml deleted file mode 100644 index 12fcd5d0bf..0000000000 --- a/content/zh/docs/user-guide/nginx-svc.yaml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: my-nginx - labels: - run: my-nginx -spec: - ports: - - port: 80 - protocol: TCP - selector: - run: my-nginx diff --git a/content/zh/docs/user-guide/pod-w-message.yaml b/content/zh/docs/user-guide/pod-w-message.yaml deleted file mode 100644 index e7fdc7d3be..0000000000 --- a/content/zh/docs/user-guide/pod-w-message.yaml +++ /dev/null @@ -1,10 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: pod-w-message -spec: - containers: - - name: messager - image: "ubuntu:14.04" - command: ["/bin/sh","-c"] - args: ["sleep 60 && /bin/echo Sleep expired > /dev/termination-log"] diff --git a/content/zh/docs/user-guide/pod.yaml b/content/zh/docs/user-guide/pod.yaml deleted file mode 100644 index 7053af0be4..0000000000 --- a/content/zh/docs/user-guide/pod.yaml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: nginx - labels: - app: nginx -spec: - containers: - - name: nginx - image: nginx - ports: - - containerPort: 80 diff --git a/content/zh/docs/user-guide/redis-deployment.yaml b/content/zh/docs/user-guide/redis-deployment.yaml deleted file mode 100644 index eacaa6feea..0000000000 --- a/content/zh/docs/user-guide/redis-deployment.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: redis -spec: - template: - metadata: - labels: - app: redis - tier: backend - spec: - # Provision a fresh volume for the pod - volumes: - - name: data - emptyDir: {} - containers: - - name: redis - image: kubernetes/redis:v1 - ports: - - containerPort: 6379 - # Mount the volume into the pod - volumeMounts: - - mountPath: /redis-master-data - name: data # must match the name of the volume, above diff --git a/content/zh/docs/user-guide/redis-resource-deployment.yaml b/content/zh/docs/user-guide/redis-resource-deployment.yaml deleted file mode 100644 index f597f9bb74..0000000000 --- a/content/zh/docs/user-guide/redis-resource-deployment.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: redis -spec: - template: - metadata: - labels: - app: redis - tier: backend - spec: - containers: - - name: redis - image: kubernetes/redis:v1 - ports: - - containerPort: 80 - resources: - limits: - # cpu units are cores - cpu: 500m - # memory units are bytes - memory: 64Mi - requests: - # cpu units are cores - cpu: 500m - # memory units are bytes - memory: 64Mi diff --git a/content/zh/docs/user-guide/redis-secret-deployment.yaml b/content/zh/docs/user-guide/redis-secret-deployment.yaml deleted file mode 100644 index a7201802ec..0000000000 --- a/content/zh/docs/user-guide/redis-secret-deployment.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: apps/v1beta1 -kind: Deployment -metadata: - name: redis -spec: - template: - metadata: - labels: - app: redis - tier: backend - spec: - volumes: - - name: data - emptyDir: {} - - name: supersecret # The "mysecret" secret populates this "supersecret" volume. - secret: - secretName: mysecret - containers: - - name: redis - image: kubernetes/redis:v1 - ports: - - containerPort: 6379 - volumeMounts: - - mountPath: /redis-master-data - name: data - - mountPath: /var/run/secrets/super # Mount the "supersecret" volume into the pod. - name: supersecret diff --git a/content/zh/docs/user-guide/run-my-nginx.yaml b/content/zh/docs/user-guide/run-my-nginx.yaml deleted file mode 100644 index 76a879f5c4..0000000000 --- a/content/zh/docs/user-guide/run-my-nginx.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: my-nginx -spec: - selector: - matchLabels: - run: my-nginx - replicas: 2 - template: - metadata: - labels: - run: my-nginx - spec: - containers: - - name: my-nginx - image: nginx - ports: - - containerPort: 80 -