ss.yaml 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. apiVersion: apps/v1
  2. kind: StatefulSet
  3. metadata:
  4. name: cecfdev
  5. namespace: dev
  6. spec:
  7. selector:
  8. matchLabels:
  9. app: cecfdev
  10. replicas: 1
  11. updateStrategy:
  12. type: RollingUpdate
  13. serviceName: cecfdev
  14. podManagementPolicy: OrderedReady
  15. template:
  16. metadata:
  17. labels:
  18. app: cecfdev
  19. app.kubernetes.io/name: cecfdev
  20. spec:
  21. affinity:
  22. nodeAffinity:
  23. requiredDuringSchedulingIgnoredDuringExecution:
  24. nodeSelectorTerms:
  25. - matchExpressions:
  26. - key: kubernetes.io/hostname
  27. operator: In
  28. values:
  29. - k8sw4
  30. securityContext:
  31. fsGroup: 1000
  32. volumes:
  33. - name: pydev-data
  34. persistentVolumeClaim:
  35. claimName: pydev-pvc
  36. containers:
  37. - name: pydev
  38. image: reg.cestong.com.cn/cecf/dev
  39. env:
  40. - name: LANG
  41. value: C.UTF8
  42. - name: LANGUAGE
  43. value: en_US:en
  44. - name: LC_ALL
  45. value: en_US.UTF-8
  46. resources:
  47. limits:
  48. ephemeral-storage: "10Gi"
  49. memory: 4000Mi
  50. cpu: 2
  51. imagePullPolicy: Always
  52. ports:
  53. - name: ssh
  54. containerPort: 22
  55. - name: service
  56. containerPort: 8686
  57. volumeMounts:
  58. - mountPath: "/home"
  59. name: pydev-data