Skip to content

Instantly share code, notes, and snippets.

@yuucu
Last active June 21, 2022 18:18
Show Gist options
  • Save yuucu/a71a03edbdf6470e29b9d4c9cb461fd1 to your computer and use it in GitHub Desktop.
Save yuucu/a71a03edbdf6470e29b9d4c9cb461fd1 to your computer and use it in GitHub Desktop.
opensearch docker sample
version: '3'
services:
opensearch-dashboards:
image: opensearchproject/opensearch-dashboards:1.0.1
container_name: opensearch-dashboards
environment:
OPENSEARCH_HOSTS: "https://opensearch:9200"
ports:
- 5601:5601
links:
- opensearch
networks:
- sandbox
opensearch:
build:
context: .
dockerfile: Dockerfile
container_name: opensearch
environment:
- cluster.name=docker-cluster
- node.name=os-node
- cluster.initial_master_nodes=os-node
- bootstrap.memory_lock=true
- http.host=0.0.0.0
- transport.host=127.0.0.1
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- $PWD/.local/opensearch:/usr/share/opensearch/data
ports:
- 9200:9200
networks:
- sandbox
networks:
sandbox:
FROM opensearchproject/opensearch:1.2.0
RUN /usr/share/opensearch/bin/opensearch-plugin install analysis-kuromoji
RUN /usr/share/opensearch/bin/opensearch-plugin install analysis-icu
# 起動
docker-compose up -d
#
curl -XGET https://localhost:9200 -u 'admin:admin' --insecure
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment