-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
86 lines (80 loc) · 2.24 KB
/
docker-compose.yml
File metadata and controls
86 lines (80 loc) · 2.24 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
version: '3.8'
services:
github-proxy:
build:
context: .
dockerfile: Dockerfile
container_name: github-proxy
ports:
- "8080:8080" # HTTP server
- "2222:2222" # SSH server
- "9090:9090" # Metrics
volumes:
- cache-data:/var/cache/github-proxy
- ./configs/config.yaml:/app/configs/config.yaml:ro
environment:
- GITHUB_PROXY_LOGGING_LEVEL=info
- GITHUB_PROXY_CACHE_DISK_PATH=/var/cache/github-proxy
# Uncomment to enable proxy
# - GITHUB_PROXY_PROXY_ENABLED=true
# - GITHUB_PROXY_PROXY_TYPE=socks5
# - GITHUB_PROXY_PROXY_ADDRESS=socks5-proxy:1080
restart: unless-stopped
networks:
- github-proxy-net
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:8080/"]
interval: 30s
timeout: 3s
retries: 3
start_period: 5s
# Optional: SOCKS5 proxy for routing GitHub traffic
# Uncomment if you need a SOCKS5 proxy
# socks5-proxy:
# image: serjs/go-socks5-proxy
# container_name: socks5-proxy
# ports:
# - "1080:1080"
# restart: unless-stopped
# networks:
# - github-proxy-net
# Optional: Prometheus for metrics collection
# Uncomment if you want to run Prometheus locally
# prometheus:
# image: prom/prometheus:latest
# container_name: prometheus
# ports:
# - "9091:9090"
# volumes:
# - ./prometheus.yml:/etc/prometheus/prometheus.yml:ro
# - prometheus-data:/prometheus
# command:
# - '--config.file=/etc/prometheus/prometheus.yml'
# - '--storage.tsdb.path=/prometheus'
# restart: unless-stopped
# networks:
# - github-proxy-net
# Optional: Grafana for metrics visualization
# Uncomment if you want to run Grafana locally
# grafana:
# image: grafana/grafana:latest
# container_name: grafana
# ports:
# - "3000:3000"
# volumes:
# - grafana-data:/var/lib/grafana
# environment:
# - GF_SECURITY_ADMIN_PASSWORD=admin
# restart: unless-stopped
# networks:
# - github-proxy-net
networks:
github-proxy-net:
driver: bridge
volumes:
cache-data:
driver: local
# prometheus-data:
# driver: local
# grafana-data:
# driver: local