Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion config/elasticsearch/.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
ELASTIC_PASSWORD=default
discovery.type=single-node
xpack.security.enabled=false
xpack.security.enabled=true
xpack.security.authc.anonymous.username=anonymous_user
xpack.security.authc.anonymous.roles=read_all
xpack.security.authc.anonymous.authz_exception=false
4 changes: 4 additions & 0 deletions config/elasticsearch/roles.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
read_all:
indices:
- names: [ "*" ]
privileges: [ "read", "view_index_metadata" ]
4 changes: 3 additions & 1 deletion docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,11 @@ services:
ports:
- "9200:9200" # also known as /es (nginx)
- "9300:9300"
volumes:
- ./config/elasticsearch/roles.yml:/usr/share/elasticsearch/config/roles.yml:ro
env_file: config/elasticsearch/.env
healthcheck:
test: curl 127.0.0.1:9200/_cluster/health | grep -e "green"
test: curl 127.0.0.1:9200/_cluster/health -u elastic:default | grep -e "green"
start_period: 30s
start_interval: 5s
timeout: 3s
Expand Down