添加 'CloudNative/Kubernetes/Base/使用.md'
This commit is contained in:
parent
811c7623a4
commit
ebf399cdf7
1 changed files with 222 additions and 0 deletions
222
CloudNative/Kubernetes/Base/使用.md
Normal file
222
CloudNative/Kubernetes/Base/使用.md
Normal file
|
@ -0,0 +1,222 @@
|
|||
```yaml
|
||||
kind: Deployment
|
||||
apiVersion: apps/v1
|
||||
metadata:
|
||||
name: echo-server-1
|
||||
namespace: dev
|
||||
uid: 45bddc5b-fb64-4997-8599-1718011157d4
|
||||
resourceVersion: '66568877'
|
||||
generation: 13
|
||||
creationTimestamp: '2023-09-14T10:29:28Z'
|
||||
labels:
|
||||
app: echo-server-1
|
||||
app.kubernetes.io/instance: echo-server-dev
|
||||
annotations:
|
||||
deployment.kubernetes.io/revision: '9'
|
||||
managedFields:
|
||||
- manager: cfe-apiserver
|
||||
operation: Update
|
||||
apiVersion: apps/v1
|
||||
time: '2023-09-14T11:26:44Z'
|
||||
fieldsType: FieldsV1
|
||||
fieldsV1:
|
||||
f:metadata:
|
||||
f:labels:
|
||||
.: {}
|
||||
f:app: {}
|
||||
f:app.kubernetes.io/instance: {}
|
||||
f:spec:
|
||||
f:progressDeadlineSeconds: {}
|
||||
f:replicas: {}
|
||||
f:revisionHistoryLimit: {}
|
||||
f:selector: {}
|
||||
f:strategy:
|
||||
f:rollingUpdate:
|
||||
.: {}
|
||||
f:maxSurge: {}
|
||||
f:maxUnavailable: {}
|
||||
f:type: {}
|
||||
f:template:
|
||||
f:metadata:
|
||||
f:labels:
|
||||
.: {}
|
||||
f:app: {}
|
||||
f:spec:
|
||||
f:containers:
|
||||
k:{"name":"runtime"}:
|
||||
.: {}
|
||||
f:command: {}
|
||||
f:env:
|
||||
.: {}
|
||||
k:{"name":"ARGS"}:
|
||||
.: {}
|
||||
f:name: {}
|
||||
f:valueFrom:
|
||||
.: {}
|
||||
f:configMapKeyRef: {}
|
||||
k:{"name":"JAVA_OPTS"}:
|
||||
.: {}
|
||||
f:name: {}
|
||||
f:valueFrom:
|
||||
.: {}
|
||||
f:configMapKeyRef: {}
|
||||
f:image: {}
|
||||
f:imagePullPolicy: {}
|
||||
f:name: {}
|
||||
f:ports:
|
||||
.: {}
|
||||
k:{"containerPort":48080,"protocol":"TCP"}:
|
||||
.: {}
|
||||
f:containerPort: {}
|
||||
f:name: {}
|
||||
f:protocol: {}
|
||||
f:resources: {}
|
||||
f:terminationMessagePath: {}
|
||||
f:terminationMessagePolicy: {}
|
||||
f:volumeMounts:
|
||||
.: {}
|
||||
k:{"mountPath":"/opt"}:
|
||||
.: {}
|
||||
f:mountPath: {}
|
||||
f:name: {}
|
||||
f:readOnly: {}
|
||||
f:dnsPolicy: {}
|
||||
f:imagePullSecrets:
|
||||
.: {}
|
||||
k:{"name":"swrregistrykey"}: {}
|
||||
f:initContainers:
|
||||
.: {}
|
||||
k:{"name":"busybox"}:
|
||||
.: {}
|
||||
f:command: {}
|
||||
f:image: {}
|
||||
f:imagePullPolicy: {}
|
||||
f:name: {}
|
||||
f:resources: {}
|
||||
f:terminationMessagePath: {}
|
||||
f:terminationMessagePolicy: {}
|
||||
f:volumeMounts:
|
||||
.: {}
|
||||
k:{"mountPath":"/tmp"}:
|
||||
.: {}
|
||||
f:mountPath: {}
|
||||
f:name: {}
|
||||
f:restartPolicy: {}
|
||||
f:schedulerName: {}
|
||||
f:securityContext: {}
|
||||
f:terminationGracePeriodSeconds: {}
|
||||
f:volumes:
|
||||
.: {}
|
||||
k:{"name":"work"}:
|
||||
.: {}
|
||||
f:emptyDir: {}
|
||||
f:name: {}
|
||||
- manager: kube-controller-manager
|
||||
operation: Update
|
||||
apiVersion: apps/v1
|
||||
time: '2023-09-14T11:26:47Z'
|
||||
fieldsType: FieldsV1
|
||||
fieldsV1:
|
||||
f:metadata:
|
||||
f:annotations:
|
||||
.: {}
|
||||
f:deployment.kubernetes.io/revision: {}
|
||||
f:status:
|
||||
f:availableReplicas: {}
|
||||
f:conditions:
|
||||
.: {}
|
||||
k:{"type":"Available"}:
|
||||
.: {}
|
||||
f:lastTransitionTime: {}
|
||||
f:lastUpdateTime: {}
|
||||
f:message: {}
|
||||
f:reason: {}
|
||||
f:status: {}
|
||||
f:type: {}
|
||||
k:{"type":"Progressing"}:
|
||||
.: {}
|
||||
f:lastTransitionTime: {}
|
||||
f:lastUpdateTime: {}
|
||||
f:message: {}
|
||||
f:reason: {}
|
||||
f:status: {}
|
||||
f:type: {}
|
||||
f:observedGeneration: {}
|
||||
f:readyReplicas: {}
|
||||
f:replicas: {}
|
||||
f:updatedReplicas: {}
|
||||
subresource: status
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: echo-server-1
|
||||
template:
|
||||
metadata:
|
||||
creationTimestamp: null
|
||||
labels:
|
||||
app: echo-server-1
|
||||
spec:
|
||||
volumes:
|
||||
- name: work
|
||||
emptyDir: {}
|
||||
initContainers:
|
||||
- name: busybox
|
||||
image: server:202309141053
|
||||
command:
|
||||
- cp
|
||||
- /opt/app.jar
|
||||
- /tmp
|
||||
resources: {}
|
||||
volumeMounts:
|
||||
- name: work
|
||||
mountPath: /tmp
|
||||
terminationMessagePath: /dev/termination-log
|
||||
terminationMessagePolicy: File
|
||||
imagePullPolicy: IfNotPresent
|
||||
containers:
|
||||
- name: runtime
|
||||
image: openjdk:8-jdk
|
||||
command:
|
||||
- java
|
||||
- '-jar'
|
||||
- /opt/app.jar
|
||||
- $ARGS
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: 48080
|
||||
protocol: TCP
|
||||
env:
|
||||
- name: JAVA_OPTS
|
||||
valueFrom:
|
||||
configMapKeyRef:
|
||||
name: echo-server-cm
|
||||
key: JAVA_OPTS
|
||||
- name: ARGS
|
||||
valueFrom:
|
||||
configMapKeyRef:
|
||||
name: echo-server-cm
|
||||
key: ARGS
|
||||
resources: {}
|
||||
volumeMounts:
|
||||
- name: work
|
||||
readOnly: true
|
||||
mountPath: /opt
|
||||
terminationMessagePath: /dev/termination-log
|
||||
terminationMessagePolicy: File
|
||||
imagePullPolicy: IfNotPresent
|
||||
restartPolicy: Always
|
||||
terminationGracePeriodSeconds: 30
|
||||
dnsPolicy: ClusterFirst
|
||||
securityContext: {}
|
||||
imagePullSecrets:
|
||||
- name: swrregistrykey
|
||||
schedulerName: default-scheduler
|
||||
strategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxUnavailable: 25%
|
||||
maxSurge: 25%
|
||||
revisionHistoryLimit: 10
|
||||
progressDeadlineSeconds: 600
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue