-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
38 lines (36 loc) · 986 Bytes
/
docker-compose.yml
File metadata and controls
38 lines (36 loc) · 986 Bytes
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
services:
igrp-eureka-server:
build: .
container_name: igrp-eureka-server
ports:
- "8761:8761"
environment:
- HOSTNAME=igrp-eureka-server
- EUREKA_SELF_PRESERVATION=true
- ROOT_LOG_LEVEL=INFO
networks:
- igrp-network
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:8761/actuator/health" ]
interval: 15s
timeout: 10s
retries: 5
start_period: 30s
# Example client service to test registration
test-client:
image: eclipse-temurin:21-jdk-alpine
container_name: test-client
command: >
sh -c "
echo 'Testing Eureka server...' &&
sleep 10 &&
wget -q --spider http://igrp-eureka-server:8761/eureka/apps || exit 1 &&
echo 'Eureka server is running!' &&
wget -qO- http://igrp-eureka-server:8761/eureka/apps | head -20 &&
tail -f /dev/null
"
networks:
- igrp-network
networks:
igrp-network:
driver: bridge