mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-17 23:12:23 +00:00
feat(compose): add judge4c and postgres services, update lsp-c and lsp-cpp configurations, and change network to judge4c
This commit is contained in:
parent
ef6de27957
commit
34266de048
56
compose.yml
56
compose.yml
@ -1,15 +1,22 @@
|
||||
services:
|
||||
monaco-editor-lsp-next:
|
||||
image: cfngc4594/monaco-editor-lsp-next:latest
|
||||
container_name: monaco-editor-lsp-next
|
||||
judge4c:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
image: judge4c:latest
|
||||
container_name: judge4c
|
||||
restart: always
|
||||
ports:
|
||||
- "3000:3000"
|
||||
networks:
|
||||
- monaco-editor-lsp-next
|
||||
- judge4c
|
||||
depends_on:
|
||||
- lsp-c
|
||||
- lsp-cpp
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
lsp-c:
|
||||
condition: service_healthy
|
||||
lsp-cpp:
|
||||
condition: service_healthy
|
||||
healthcheck:
|
||||
test: [ "CMD-SHELL", "curl --fail http://localhost:3000 || exit 1" ]
|
||||
interval: 10s
|
||||
@ -20,13 +27,16 @@ services:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
|
||||
lsp-c:
|
||||
image: cfngc4594/lsp-c:latest
|
||||
build:
|
||||
context: ./docker/lsp/clangd
|
||||
dockerfile: Dockerfile
|
||||
image: lsp-c:latest
|
||||
container_name: lsp-c
|
||||
restart: always
|
||||
ports:
|
||||
- "4594:3000"
|
||||
networks:
|
||||
- monaco-editor-lsp-next
|
||||
- judge4c
|
||||
healthcheck:
|
||||
test: [ "CMD-SHELL", "nc -zv localhost 3000" ]
|
||||
interval: 10s
|
||||
@ -34,20 +44,40 @@ services:
|
||||
retries: 5
|
||||
|
||||
lsp-cpp:
|
||||
image: cfngc4594/lsp-cpp:latest
|
||||
build:
|
||||
context: ./docker/lsp/clangd
|
||||
dockerfile: Dockerfile
|
||||
image: lsp-cpp:latest
|
||||
container_name: lsp-cpp
|
||||
restart: always
|
||||
ports:
|
||||
- "4595:3000"
|
||||
networks:
|
||||
- monaco-editor-lsp-next
|
||||
- judge4c
|
||||
healthcheck:
|
||||
test: [ "CMD-SHELL", "nc -zv localhost 3000" ]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
postgres:
|
||||
image: postgres:16-alpine
|
||||
container_name: postgres
|
||||
restart: always
|
||||
environment:
|
||||
- POSTGRES_USER=${POSTGRES_USER}
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
- POSTGRES_DB=${POSTGRES_DB}
|
||||
ports:
|
||||
- "5432:5432"
|
||||
networks:
|
||||
monaco-editor-lsp-next:
|
||||
name: monaco-editor-lsp-next
|
||||
driver: bridge
|
||||
- judge4c
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U postgres -d postgres"]
|
||||
interval: 5s
|
||||
timeout: 2s
|
||||
retries: 20
|
||||
|
||||
networks:
|
||||
judge4c:
|
||||
name: judge4c
|
||||
|
Loading…
Reference in New Issue
Block a user