chore: add Drone CI/CD, docker-compose, deploy script and update Dockerfile to Java 21
This commit is contained in:
32
docker-compose.yml
Normal file
32
docker-compose.yml
Normal file
@@ -0,0 +1,32 @@
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
app:
|
||||
image: 192.168.31.253/yescent/par:latest
|
||||
container_name: par-server
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "${APP_PORT:-9012}:8080"
|
||||
volumes:
|
||||
- ${DATA_ROOT:-./data}/static/configs:/app/static/configs
|
||||
- ${DATA_ROOT:-./data}/static/admin:/app/static/admin
|
||||
- ${LOG_ROOT:-./logs}:/app/logs
|
||||
environment:
|
||||
TZ: "Asia/Shanghai"
|
||||
JAVA_OPTS: "-Xms256m -Xmx512m"
|
||||
MYSQL_HOST: "${MYSQL_HOST:-host.docker.internal}"
|
||||
MYSQL_PORT: "${MYSQL_PORT:-3306}"
|
||||
MYSQL_DB: "${MYSQL_DB:-par_registry}"
|
||||
MYSQL_USER: "${MYSQL_USER:-root}"
|
||||
MYSQL_PASSWORD: "${MYSQL_PASSWORD:-root}"
|
||||
HMAC_SECRET: "${HMAC_SECRET:-}"
|
||||
PAR_STATIC_PATH: "/app/static"
|
||||
PAR_ADMIN_PATH: "/app/static/admin"
|
||||
extra_hosts:
|
||||
- "host.docker.internal:host-gateway"
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "-qO-", "http://localhost:8080/health"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
Reference in New Issue
Block a user