Docker Desktop Elasticsearch nodes. socket hang up

I have my docker-compose.override.yml set up below in Visual Studio 2022 for development purposes.

elasticsearch:
    container_name: elasticsearch
    environment:
        - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
        - discovery.type=single-node
    restart: always
    ports:
        - "9200:9200"
        - "9300:9300"
    networks: 
      elastic:

  kibana:
    container_name: kibana
    restart: always
    environment:
        - ELASTICSEARCH_HOSTS=http://elasticsearch:9200
    depends_on:
        - elasticsearch
    ports:
        - "5601:5601"
    networks: 
      elastic:

networks:
  elastic:
    driver: bridge

Every time I try to configure kibana, after supplying a token, I get the following error w/out kibana getting fully configured. I have tried both automatic and manual configuration, but get the same error. Is there a misconfiguration with my docker file? Below is the output from my Kibana container.

2023-02-06 21:40:38 [2023-02-07T04:40:38.210+00:00][WARN ][plugins.alerting] APIs are disabled because the Encrypted Saved Objects plugin is missing encryption key. Please set xpack.encryptedSavedObjects.encryptionKey in the kibana.yml or use the bin/kibana-encryption-keys command.
2023-02-06 21:40:38 [2023-02-07T04:40:38.366+00:00][INFO ][plugins.ruleRegistry] Installing common resources shared between all indices
2023-02-06 21:40:38 [2023-02-07T04:40:38.508+00:00][INFO ][plugins.cloudSecurityPosture] Registered task successfully [Task: cloud_security_posture-stats_task]
2023-02-06 21:40:39 [2023-02-07T04:40:39.605+00:00][INFO ][plugins.screenshotting.config] Chromium sandbox provides an additional layer of protection, and is supported for Linux Ubuntu 20.04 OS. Automatically enabling Chromium sandbox.
2023-02-06 21:40:39 [2023-02-07T04:40:39.741+00:00][ERROR][elasticsearch-service] Unable to retrieve version information from Elasticsearch nodes. socket hang up - Local: 192.168.128.3:60856, Remote: 192.168.128.2:9200
2023-02-06 21:40:40 [2023-02-07T04:40:40.773+00:00][INFO ][plugins.screenshotting.chromium] Browser executable: /usr/share/kibana/x-pack/plugins/screenshotting/chromium/headless_shell-linux_x64/headless_shell
2023-02-06 21:40:42 [2023-02-07T04:40:42.194+00:00][ERROR][elasticsearch-service] Unable to retrieve version information from Elasticsearch nodes. socket hang up - Local: 192.168.128.3:44378, Remote: 192.168.128.2:9200

Any help appreciated.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.