odoo k8s note

minikube k8s v1.6.0

---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: db-postgres
  annotations:
    k8s.kuboard.cn/workload: db-postgres
    deployment.kubernetes.io/revision: '1'
    k8s.eip.work/displayName: db-postgres
    k8s.eip.work/ingress: 'false'
    k8s.eip.work/service: ClusterIP
    k8s.eip.work/workload: db-postgres
    k8s.kuboard.cn/ingress: 'false'
    k8s.kuboard.cn/service: ClusterIP
  labels:
    k8s.eip.work/layer: db
    k8s.eip.work/name: db-postgres
spec:
  selector:
    matchLabels:
      k8s.eip.work/layer: db
      k8s.eip.work/name: db-postgres
  revisionHistoryLimit: 10
  template:
    metadata:
      labels:
        k8s.eip.work/layer: db
        k8s.eip.work/name: db-postgres
    spec:
      securityContext:
        seLinuxOptions: {}
      imagePullSecrets:
        - name: dockerhub
      restartPolicy: Always
      initContainers: []
      containers:
        - image: 'postgres:10'
          imagePullPolicy: Always
          name: postgres-odoo
          volumeMounts: []
          resources:
            limits:
            requests:
          env:
            - name: POSTGRES_DB
              value: postgres
            - name: POSTGRES_PASSWORD
              value: odoo
            - name: POSTGRES_USER
              value: yourpassword
          lifecycle: {}
          terminationMessagePath: /dev/termination-log
          terminationMessagePolicy: File
      volumes: []
      dnsPolicy: ClusterFirst
      dnsConfig: {}
      schedulerName: default-scheduler
      terminationGracePeriodSeconds: 30
  progressDeadlineSeconds: 600
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxUnavailable: 25%
      maxSurge: 25%
  replicas: 1
---
apiVersion: v1
kind: Service
metadata:
  name: db-postgres
  annotations:
    k8s.kuboard.cn/workload: db-postgres
    k8s.eip.work/displayName: db-postgres
    k8s.eip.work/workload: db-postgres
  labels:
    k8s.eip.work/layer: db
    k8s.eip.work/name: db-postgres
spec:
  selector:
    k8s.eip.work/layer: db
    k8s.eip.work/name: db-postgres
  type: ClusterIP
  ports:
    - port: 5432
      targetPort: 5432
      protocol: TCP
      name: fp6ksw
      nodePort: 0
  sessionAffinity: None
 
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: web-odoo
  annotations:
    k8s.kuboard.cn/workload: web-odoo
    deployment.kubernetes.io/revision: '5'
    k8s.eip.work/displayName: web-odoo
    k8s.eip.work/ingress: 'true'
    k8s.eip.work/service: ClusterIP
    k8s.eip.work/workload: web-odoo
    k8s.kuboard.cn/ingress: 'true'
    k8s.kuboard.cn/service: ClusterIP
  labels:
    k8s.eip.work/layer: web
    k8s.eip.work/name: web-odoo
spec:
  selector:
    matchLabels:
      k8s.eip.work/layer: web
      k8s.eip.work/name: web-odoo
  revisionHistoryLimit: 10
  template:
    metadata:
      labels:
        k8s.eip.work/layer: web
        k8s.eip.work/name: web-odoo
    spec:
      securityContext:
        seLinuxOptions: {}
      imagePullSecrets: []
      restartPolicy: Always
      initContainers: []
      containers:
        - image: 'odoo:14.0'
          imagePullPolicy: Always
          name: web-odoo
          volumeMounts: []
          resources:
            limits:
            requests:
          env:
            - name: HOST
              value: db-postgres
            - name: USER
              value: odoo
            - name: PASSWORD
              value: yourpassword
          lifecycle: {}
          terminationMessagePath: /dev/termination-log
          terminationMessagePolicy: File
      volumes: []
      dnsPolicy: ClusterFirst
      dnsConfig: {}
      schedulerName: default-scheduler
      terminationGracePeriodSeconds: 30
  progressDeadlineSeconds: 600
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxUnavailable: 25%
      maxSurge: 25%
  replicas: 1
 
---
apiVersion: v1
kind: Service
metadata:
  name: web-odoo
  annotations:
    k8s.kuboard.cn/workload: web-odoo
    k8s.eip.work/displayName: web-odoo
    k8s.eip.work/workload: web-odoo
  labels:
    k8s.eip.work/layer: web
    k8s.eip.work/name: web-odoo
spec:
  selector:
    k8s.eip.work/layer: web
    k8s.eip.work/name: web-odoo
  type: ClusterIP
  ports:
    - port: 8069
      targetPort: 8069
      protocol: TCP
      name: mawfrp
      nodePort: 0
  sessionAffinity: None
 
---
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
  name: web-odoo
  annotations:
    k8s.kuboard.cn/workload: web-odoo
    k8s.eip.work/displayName: web-odoo
    k8s.eip.work/workload: web-odoo
  labels:
    k8s.eip.work/layer: web
    k8s.eip.work/name: web-odoo
spec:
  rules:
    - host: www.odoo14.hrsoft.com
      http:
        paths:
          - path: /
            backend:
              serviceName: web-odoo
              servicePort: mawfrp
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

ziix

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值