找不到persistentvolumeclaim“ esdata1”,或者pod具有未绑定的PersistentVolumeClaims

时间:2019-04-13 10:23:37

标签: docker kubernetes

这是我的docker-compose.yml文件

version: '3'
services:
  elasticsearch:
      image: docker.elastic.co/elasticsearch/elasticsearch:6.6.0
      container_name: elasticsearch
      environment:
        - cluster.name=elstic-cluster
        - bootstrap.memory_lock=true
        - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
      ulimits:
        memlock:
          soft: -1
          hard: -1
      volumes:
        - esdata1:/usr/share/elasticsearch/data
      ports:
        - 9200:9200
      networks:
        - hcnet

我遇到错误:找不到“ persistentvolumeclaim“ esdata1” 后退重启失败的容器”

但是创建了pvc“ esdata1”。为什么会出现此问题?

enter image description here

enter image description here

0 个答案:

没有答案