Basic Rest API implementation
This commit is contained in:
52
compose.yml
Normal file
52
compose.yml
Normal file
@ -0,0 +1,52 @@
|
||||
services:
|
||||
mongodb:
|
||||
image: mongo:8.0
|
||||
container_name: blitz-mongodb
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
MONGO_INITDB_DATABASE: hysteria
|
||||
volumes:
|
||||
- mongodb_data:/data/db
|
||||
networks:
|
||||
- blitz-network
|
||||
healthcheck:
|
||||
test: echo 'db.runCommand("ping").ok' | mongosh localhost:27017/test --quiet
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
blitz-api:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
container_name: blitz-api
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "8000:8000"
|
||||
- "443:443"
|
||||
- "80:80"
|
||||
environment:
|
||||
- MONGODB_URI=mongodb://mongodb:27017/hysteria
|
||||
- PYTHONUNBUFFERED=1
|
||||
volumes:
|
||||
- ./core:/etc/hysteria/core
|
||||
- blitz_config:/etc/hysteria
|
||||
- blitz_certs:/root/.acme.sh
|
||||
networks:
|
||||
- blitz-network
|
||||
depends_on:
|
||||
mongodb:
|
||||
condition: service_healthy
|
||||
privileged: true
|
||||
cap_add:
|
||||
- NET_ADMIN
|
||||
- SYS_MODULE
|
||||
|
||||
networks:
|
||||
blitz-network:
|
||||
driver: bridge
|
||||
|
||||
volumes:
|
||||
mongodb_data:
|
||||
blitz_config:
|
||||
blitz_certs:
|
||||
Reference in New Issue
Block a user