-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
103 lines (99 loc) · 4.15 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
version: "3"
services:
opensearch-node1: # This is also the hostname of the container within the Docker network (i.e. https://opensearch-node1/)
image: opensearchproject/opensearch:latest
container_name: opensearch-node1
hostname: opensearch-node1
# command: bash -c "sysctl -w vm.max_map_count=262144" # <--- I should pass this as environment variable
environment:
- cluster.name=opensearch-cluster # Name the cluster
- node.name=opensearch-node1 # Name the node that will run in this container
- discovery.seed_hosts=opensearch-node1,opensearch-node2 # Nodes to look for when discovering the cluster
- cluster.initial_cluster_manager_nodes=opensearch-node1,opensearch-node2 # Nodes eligibile to serve as cluster manager
- bootstrap.memory_lock=true # Disable JVM heap memory swapping
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m" # Set min and max JVM heap sizes to at least 50% of system RAM
- OPENSEARCH_INITIAL_ADMIN_PASSWORD=${OPENSEARCH_INITIAL_ADMIN_PASSWORD} # Sets the demo admin user password when using demo configuration (for OpenSearch 2.12 and later)
ulimits:
memlock:
soft: -1 # Set memlock to unlimited (no soft or hard limit)
hard: -1
nofile:
soft: 262144 # Maximum number of open files for the opensearch user - set to at least 65536
hard: 262144
volumes:
- opensearch-data1:/usr/share/opensearch/data # Creates volume called opensearch-data1 and mounts it to the container
ports:
- 9200:9200 # REST API
- 9600:9600 # Performance Analyzer
networks:
- opensearch-net # All of the containers will join the same Docker bridge network
opensearch-node2:
image: opensearchproject/opensearch:latest # This should be the same image used for opensearch-node1 to avoid issues
# command: bash -c "sysctl -w vm.max_map_count=262144" # <--- I should pass this as environment variable
container_name: opensearch-node2
environment:
- cluster.name=opensearch-cluster
- node.name=opensearch-node2
- discovery.seed_hosts=opensearch-node1,opensearch-node2
- cluster.initial_cluster_manager_nodes=opensearch-node1,opensearch-node2
- bootstrap.memory_lock=true
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
- OPENSEARCH_INITIAL_ADMIN_PASSWORD=${OPENSEARCH_INITIAL_ADMIN_PASSWORD}
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 262144
hard: 262144
volumes:
- opensearch-data2:/usr/share/opensearch/data
networks:
- opensearch-net
opensearch-dashboards:
image: opensearchproject/opensearch-dashboards:latest # Make sure the version of opensearch-dashboards matches the version of opensearch installed on other nodes
container_name: opensearch-dashboards
ports:
- 5601:5601 # Map host port 5601 to container port 5601
expose:
- "5601" # Expose port 5601 for web access to OpenSearch Dashboards
environment:
OPENSEARCH_HOSTS: '["https://opensearch-node1:9200","https://opensearch-node2:9200"]' # Define the OpenSearch nodes that OpenSearch Dashboards will query
networks:
- opensearch-net
lamp: # this is the fornt end service
image: hrida/lamp
container_name: front_end_lamp
hostname: lamp
ports:
- 3000:3000
networks:
- opensearch-net
restart: unless-stopped
light: # this is the back end service
image: hrida/light
container_name: back_end_light
environment:
- OPENAI_API_KEY=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
- HF_AUTH=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
- VOYAGE_API_KEY=pa-pBWwn664zrcc-80y0pFExXwjRuCKQhygngCFq7DT4dI
- AZURE_SUBSCRIPTION_KEY=5eec2903-9705-470a-835a-0221fbc8d93d
- RESOURCE_GROUP_NAME=inlpt-azure-ml
- WORKSPACE_NAME=MLINLPT-Azure-ml
- ONLINE_ENDPOINT_NAME=biobert-pubmed-ml
- DEPLOYMENT_NAME=nlpt-biobert-ml
hostname: light
volumes:
- ~/.azure:/root/.azure
ports:
- 8000:8000
networks:
- opensearch-net
restart: unless-stopped
volumes:
opensearch-data1:
opensearch-data2:
networks:
opensearch-net:
driver: bridge
name: opensearch-net