OpenSearch-Dashboards icon indicating copy to clipboard operation
OpenSearch-Dashboards copied to clipboard

Cannot Start Opensearch Dashboard

Open anh2001ht opened this issue 9 months ago • 0 comments

Hello, I am using docker compose to run Opensearch, and use source code Opensearch-Dashboard then yarn start to run dashboard (to use plugin i18n). I have a problem that I can not access to dashboard Url (port 5601) because of this error :

image Here is my docker-compose.yaml

version: '3' services: opensearch: image: opensearchproject/opensearch:2.12.0 container_name: opensearch environment: - discovery.type=single-node - "ES_JAVA_OPTS=-Xms512m -Xmx512m" - compatibility.override_main_response_version=true - "OPENSEARCH_SECURITY_ENABLED=true" - "OPENSEARCH_SECURITY_AUDIT_ENABLED=true" - "OPENSEARCH_INITIAL_ADMIN_PASSWORD=mypasswordStrong123!" # - "DISABLE_INSTALL_DEMO_CONFIG=true" # - "DISABLE_SECURITY_PLUGIN=true" volumes: - ./data:/usr/share/opensearch/data - ./config/opensearch.yml:/usr/share/opensearch/config/opensearch.yml - ./certs/root-ca.pem:/usr/share/opensearch/config/root-ca.pem - ./certs/node1.pem:/usr/share/opensearch/config/node1.pem - ./certs/node1-key.pem:/usr/share/opensearch/config/node1-key.pem ports: - 9200:9200 - 9600:9600 networks: - opensearch-net networks: opensearch-net: driver: bridge

file config opensearch.yml: ` network.host: 0.0.0.0 plugins.security.ssl.transport.pemcert_filepath: node1.pem plugins.security.ssl.transport.pemkey_filepath: node1-key.pem plugins.security.ssl.transport.pemtrustedcas_filepath: root-ca.pem plugins.security.ssl.transport.enforce_hostname_verification: true plugins.security.ssl.http.enabled: false plugins.security.ssl.http.pemcert_filepath: node1.pem plugins.security.ssl.http.pemkey_filepath: node1-key.pem plugins.security.ssl.http.pemtrustedcas_filepath: root-ca.pem plugins.security.allow_unsafe_democertificates: false plugins.security.allow_default_init_securityindex: true plugins.security.nodes_dn: 'CN=node1.dns.a-record,OU=UNIT,O=ORG,L=TORONTO,ST=ONTARIO,C=CA'

file config opensearch_dashboards.yml

server.host: "0.0.0.0" opensearch.username: "admin" opensearch.password: "admin" opensearch.hosts: ["http://localhost:9200/"] i18n.locale: "ja-JP"

Can someone help me please, I can run dashboard and opensearch with docker compose sucessfully but I run dashboard with yarn start and docker compose opensearch I can not work. this is the file docker compose that both opensearch and opensearch dashboard work :

version: '3' services: opensearch: image: opensearchproject/opensearch:2.12.0 container_name: opensearch environment: - discovery.type=single-node - "ES_JAVA_OPTS=-Xms512m -Xmx512m" - compatibility.override_main_response_version=true - "OPENSEARCH_SECURITY_ENABLED=true" - "OPENSEARCH_SECURITY_AUDIT_ENABLED=true" # - "DISABLE_SECURITY_PLUGIN=true" - "OPENSEARCH_INITIAL_ADMIN_PASSWORD=mypasswordStrong123!" volumes: - ./data:/usr/share/opensearch/data - ./config/opensearch.yml:/usr/share/opensearch/config/opensearch.yml - ./certs/root-ca.pem:/usr/share/opensearch/config/root-ca.pem - ./certs/node1.pem:/usr/share/opensearch/config/node1.pem - ./certs/node1-key.pem:/usr/share/opensearch/config/node1-key.pem - ./certs/admin.pem:/usr/share/opensearch/config/admin.pem - ./certs/admin-key.pem:/usr/share/opensearch/config/admin-key.pem - ./logs/log.log:/usr/share/opensearch/logs/opensearch.log ports: - 9200:9200 networks: - opensearch-net kibana: image: opensearchproject/opensearch-dashboards:2.12.0 container_name: kibana ports: - 5601:5601 - 5603:5603 stdin_open: true tty: true expose: - "5601" - "5603" environment: - 'OPENSEARCH_HOSTS=["http://localhost:9200/"]' - 'SERVER_HOST="0.0.0.0"' - "OPENSEARCH_USERNAME=admin" - "OPENSEARCH_PASSWORD=admin" networks: - opensearch-net networks: opensearch-net: driver: bridge

anh2001ht avatar May 10 '24 04:05 anh2001ht