在AWS EKS中创建Couchdb Pod时出错

时间:2019-12-23 09:10:20

标签: kubernetes couchdb hyperledger-fabric amazon-eks

在创建每次尝试创建Pod DB部署Pod时显示"CreateContainerConfigError"时,我都遇到了AWS EKS的问题。虽然使用kubectl的调试pod描述了我遇到类似"Warning Failed 2s (x6 over 43s) kubelet, ip-192-1xx-2xx-x.us-east-2.compute.internal Error: secrets "couchdb" not found"

的错误

下面的我的部署文件。

apiVersion: apps/v1
kind: Deployment
metadata:
  name: peer0-org1-couchdb-deployment
  labels: {
    component: peer0,
    type: couchdb,
    org: org1
  }
spec:
  replicas: 1
  selector:
    matchLabels:
      component: peer0
      type: couchdb
      org: org1
  template:
    metadata:
      labels:
        component: peer0
        type: couchdb
        org: org1
    spec:
      volumes:
        - name: host-mount
          persistentVolumeClaim:
            claimName: efs-burst-persistent-volume-claim
      containers:
        - name: peer0-org1-couchdb
          image: couchdb:2.3.1
          env:
            - name: COUCHDB_USER
              valueFrom:
                secretKeyRef:
                  name: couchdb
                  key: username
            - name: COUCHDB_PASSWORD
              valueFrom:
                secretKeyRef:
                  name: couchdb
                  key: password
          volumeMounts:
            - mountPath: /opt/couchdb/data
              name: host-mount
              subPath: state/org1/peers/peer0-couchdb

任何人都知道我在做什么错。

谢谢。

0 个答案:

没有答案