Skip to content

Commit 74a2377

Browse files
authored
Merge pull request #307 from MITLibraries/opensearch-dashboard
Adds docker compose and info on using dashboard
2 parents 9e2c66f + ce04171 commit 74a2377

File tree

2 files changed

+47
-1
lines changed

2 files changed

+47
-1
lines changed

README.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,27 @@ A local OpenSearch instance can be started for development purposes by running:
3131
``` bash
3232
$ docker run -p 9200:9200 -p 9600:9600 -e "discovery.type=single-node" \
3333
-e "plugins.security.disabled=true" \
34-
opensearchproject/opensearch:2.3.0
34+
opensearchproject/opensearch:2.11.1
3535
```
3636

3737
To confirm the instance is up, run `pipenv run tim -u localhost ping`.
3838

39+
Alternately, you can use the included Docker Compose file to start an OpenSearch node along with an OpenSearch Dashboard. This should leave you with the same
40+
41+
```bash
42+
docker pull opensearchproject/opensearch:latest
43+
docker pull opensearchproject/opensearch-dashboards:latest
44+
docker compose up
45+
```
46+
47+
To confirm the instance is up, run `pipenv run tim -u localhost ping`.
48+
49+
To access the Dashboard, access <http://localhost:5601>.
50+
51+
DevTools is useful for writing/testing OpenSearch queries.
52+
53+
Discover is useful for browsing data. An index pattern will be required to use this tool. Note: do not set a date filed (choose the option to skip selecting a date field). It detects a date field in our indexes but then crashes trying to use it. Once you skip the data select field, just enter an index or alias to pull patterns from and it will automatically be configured to work well enough for initial data exploration.
54+
3955
### OpenSearch on AWS
4056

4157
1. Ensure that you have the correct AWS credentials set for the Dev1 (or desired) account.

compose.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
version: "3.8"
2+
services:
3+
opensearch:
4+
image: opensearchproject/opensearch:latest
5+
ports:
6+
- "9200:9200"
7+
- "9600:9600"
8+
environment:
9+
- plugins.security.disabled=true
10+
- discovery.type=single-node
11+
- bootstrap.memory_lock=true
12+
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
13+
volumes:
14+
- opensearch-local-data:/usr/share/opensearch/data
15+
networks:
16+
- opensearch-local-net
17+
dashboard:
18+
image: opensearchproject/opensearch-dashboards:latest
19+
ports:
20+
- "5601:5601"
21+
environment:
22+
- "DISABLE_SECURITY_DASHBOARDS_PLUGIN=true"
23+
- 'OPENSEARCH_HOSTS=["http://opensearch:9200"]'
24+
networks:
25+
- opensearch-local-net
26+
volumes:
27+
opensearch-local-data:
28+
29+
networks:
30+
opensearch-local-net:

0 commit comments

Comments
 (0)