-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompose.yaml
53 lines (47 loc) · 1.59 KB
/
compose.yaml
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
# This file will compose and run the services required for the ChainGenerator application
version: '3.8'
name: chain-generator
services:
# API that only communicates with the databases
api:
build:
context: .
dockerfile: ./ChainGenerator/Dockerfile
ports:
- "12800:8080"
- "12801:8081"
environment:
NODE_ENV: development
ConnectionStrings__DefaultConnection: "Server=chain-generator-db,1433;Database=ChainGenerator;User Id=sa;Password=yourStrong(!)Password;Trusted_Connection=false;MultipleActiveResultSets=true;TrustServerCertificate=true;"
OpenAIServiceOptions__ApiKey: ${OPEN_AI_KEY}
depends_on:
chain-generator-db:
condition: service_healthy
networks:
- frontend
- backend
# Add the MSSQL server database
chain-generator-db:
image: "mcr.microsoft.com/mssql/server:2022-latest"
environment:
ACCEPT_EULA: "Y"
MSSQL_SA_PASSWORD: "yourStrong(!)Password"
networks:
- backend
ports:
- "1444:1433"
volumes:
- chain-generator-mssql-data:/var/opt/mssql
healthcheck:
test: /opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P "yourStrong(!)Password" -Q "SELECT 1" -b -o /dev/null
interval: 5s
timeout: 2s
retries: 30
start_period: 10s
networks:
backend:
driver: bridge
frontend:
driver: bridge
volumes:
chain-generator-mssql-data: