In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly introduces the example analysis of postgresql StatefulSet on kubernetes, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.
ApiVersion: v1kind: Namespacemetadata: name: postgres---apiVersion: storage.k8s.io/v1kind: StorageClassmetadata: name: managed-nfs-storageprovisioner: fuseim.pri/ifs # or choose another name Must match deployment's env PROVISIONER_NAME'parameters: archiveOnDelete: "true"-- apiVersion: v1kind: Secretmetadata: name: postgresql namespace: postgrestype: Opaquedata: postgresql-pwd: LW4gJzExMjIzM0FiQycgDQo=---apiVersion: apps/v1kind: StatefulSetmetadata: name: postgresql namespace: postgresspec: serviceName: postgresql replicas: 1 selector: matchLabels: app: postgresql template: metadata: labels: app: postgresql spec: containers:-name: postgresql image: Postgres:12.4-alpine env:-name: POSTGRES_PASSWORD valueFrom: secretKeyRef: name: postgresql key: postgresql-pwd ports:-containerPort: 5432 name: serviceport protocol: TCP volumeMounts:-name: database mountPath: / var/lib/postgresql/data volumeClaimTemplates:-metadata: Name: database spec: accessModes: ["ReadWriteOnce"] storageClassName: "managed-nfs-storage" resources: requests: storage: v1kind: Servicemetadata: name: postgre-svc namespace: postgresspec: type: ClusterIP ports:-name: serviceport port: 5432 targetPort: 5432 protocol: TCP selector: app: postgresql---apiVersion: v1kind: Servicemetadata: name: postgres-lb namespace: postgresspec: type : LoadBalancer ports:-name: serviceport port: 5432 targetPort: 5432 protocol: TCP selector: app: postgresql Thank you for reading this article carefully I hope the article "sample Analysis of postgresql StatefulSet on kubernetes" shared by the editor will be helpful to you. At the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.