63 lines
2.7 KiB
YAML
63 lines
2.7 KiB
YAML
version: "3.8"
|
|
|
|
services:
|
|
proxy:
|
|
image: metacubex/mihomo
|
|
container_name: proxy
|
|
restart: always
|
|
ports:
|
|
- "127.0.0.1:7890:7890"
|
|
- "127.0.0.1:9090:9090"
|
|
volumes:
|
|
- ./config:/root/.config/mihomo
|
|
environment:
|
|
- MIHOMO_SECRET="your_secret_here"
|
|
- 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
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "wget -q -T 2 --header='Authorization: Bearer your_secret_here' -O - http://127.0.0.1:9090/version >/dev/null"]
|
|
interval: 10s
|
|
timeout: 3s
|
|
retries: 10
|
|
start_period: 30s
|
|
networks:
|
|
- proxy_net
|
|
|
|
jenkins:
|
|
image: jenkins/jenkins:latest
|
|
container_name: jenkins
|
|
restart: always
|
|
ports:
|
|
- "8080:8080"
|
|
- "50000:50000"
|
|
volumes:
|
|
- ./jenkins_home:/var/jenkins_home
|
|
- /etc/localtime:/etc/localtime:ro
|
|
networks:
|
|
- proxy_net
|
|
depends_on:
|
|
proxy:
|
|
condition: service_healthy
|
|
environment:
|
|
JENKINS_UC: https://mirrors.tuna.tsinghua.edu.cn/jenkins/updates/update-center.json
|
|
JENKINS_UC_EXPERIMENTAL: https://mirrors.tuna.tsinghua.edu.cn/jenkins/updates/experimental/update-center.json
|
|
JENKINS_UC_DOWNLOAD: https://mirrors.tuna.tsinghua.edu.cn/jenkins
|
|
HTTP_PROXY: http://proxy:7890
|
|
http_proxy: http://proxy:7890
|
|
HTTPS_PROXY: http://proxy:7890
|
|
https_proxy: http://proxy:7890
|
|
NO_PROXY: localhost,127.0.0.1,::1,jenkins,proxy,.local,.lan,.internal,.mirrors.tuna.tsinghua.edu.cn,.jenkins.io,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16
|
|
no_proxy: localhost,127.0.0.1,::1,jenkins,proxy,.local,.lan,.internal,.mirrors.tuna.tsinghua.edu.cn,.jenkins.io,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16
|
|
JAVA_TOOL_OPTIONS: >
|
|
-Dhttp.proxyHost=proxy
|
|
-Dhttp.proxyPort=7890
|
|
-Dhttps.proxyHost=proxy
|
|
-Dhttps.proxyPort=7890
|
|
-Dhttp.nonProxyHosts=localhost|127.*|[::1]|jenkins|proxy|*.local|*.lan|*.internal|10.*|172.16.*|172.17.*|172.18.*|172.19.*|172.20.*|172.21.*|172.22.*|172.23.*|172.24.*|172.25.*|172.26.*|172.27.*|172.28.*|172.29.*|172.30.*|172.31.*|192.168.*|*.jenkins.io|mirrors.tuna.tsinghua.edu.cn
|
|
-Dhttps.nonProxyHosts=localhost|127.*|[::1]|jenkins|proxy|*.local|*.lan|*.internal|10.*|172.16.*|172.17.*|172.18.*|172.19.*|172.20.*|172.21.*|172.22.*|172.23.*|172.24.*|172.25.*|172.26.*|172.27.*|172.28.*|172.29.*|172.30.*|172.31.*|192.168.*|*.jenkins.io|mirrors.tuna.tsinghua.edu.cn
|
|
-Djdk.tls.client.protocols=TLSv1.2 -Dhttps.protocols=TLSv1.2
|
|
|
|
networks:
|
|
proxy_net:
|
|
external: true
|