deployment.yaml 947 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. apiVersion: apps/v1
  2. kind: Deployment
  3. metadata:
  4. name: diagnosis
  5. namespace: dev
  6. labels:
  7. app: appointment
  8. spec:
  9. replicas: 1
  10. revisionHistoryLimit: 10
  11. selector:
  12. matchLabels:
  13. app: diagnosis
  14. strategy:
  15. rollingUpdate:
  16. maxSurge: 1
  17. maxUnavailable: 0
  18. type: RollingUpdate
  19. template:
  20. metadata:
  21. labels:
  22. app: diagnosis
  23. spec:
  24. containers:
  25. - args:
  26. - --spring.profiles.active=dev
  27. image: yaoxiang/diagnosis:${date}
  28. imagePullPolicy: IfNotPresent
  29. name: diagnosis
  30. ports:
  31. - containerPort: 8080
  32. name: 8080tcp01
  33. protocol: TCP
  34. ---
  35. apiVersion: v1
  36. kind: Service
  37. metadata:
  38. name: diagnosis
  39. namespace: dev
  40. labels:
  41. app: diagnosis
  42. spec:
  43. selector:
  44. app: diagnosis
  45. type: NodePort
  46. ports:
  47. - port: 8080
  48. targetPort: 8080
  49. nodePort: 32003
  50. name: "http"
  51. protocol: TCP