This commit is contained in:
mm644706215
2025-09-30 23:51:40 +08:00
parent df95b6690b
commit 5899abe0b7
6 changed files with 155 additions and 207 deletions

View File

@@ -1,13 +1,32 @@
version: "3.9"
services:
v2ray-client:
image: v2fly/v2fly-core:latest
container_name: v2ray-client
restart: unless-stopped
volumes:
- ./v2ray-client.json:/etc/v2ray/config.json:ro
command: ["run", "-c", "/etc/v2ray/config.json"]
proxy:
image: metacubex/mihomo
container_name: proxy
restart: always
# 只绑定本地回环地址
ports:
- "127.0.0.1:11080:11080" # SOCKS5
- "127.0.0.1:18080:18080" # HTTP
- "0.0.0.0:7890:7890" # mixed-port (HTTP/SOCKS)
- "7891:7891" # SOCKS5 代理
- "127.0.0.1:9090:9090" # API 控制口
volumes:
- ./config:/root/.config/mihomo
environment:
- GEOIP_URL=https://ghproxy.dockless.eu.org//https://github.com/MetaCubeX/meta-rules-dat/releases/download/latest/geoip.metadb
- GEOSITE_URL=https://ghproxy.dockless.eu.org/https://github.com/MetaCubeX/meta-rules-dat/releases/download/latest/geosite.dat
- SUBSCRIPTION_URL=https://app.mitce.net/?sid=303534&token=srveqevu
healthcheck:
test:
[
"CMD-SHELL",
"netstat -tln | grep -q ':7890'"
]
interval: 10s
timeout: 5s
retries: 3
start_period: 10s
networks:
- proxy_net
networks:
proxy_net:
external: true