Skip to content

Commit

Permalink
lug: remove dockerhub by regulation (#470)
Browse files Browse the repository at this point in the history
  • Loading branch information
PhotonQuantum authored Jun 6, 2024
1 parent 516c26a commit eaaec27
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 24 deletions.
18 changes: 0 additions & 18 deletions caddy/Caddyfile.zhiyuan
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,6 @@ registry-k8s-io.mirrors.sjtug.sjtu.edu.cn {
header * x-sjtug-mirror-id zhiyuan
}

docker.mirrors.sjtug.sjtu.edu.cn {
log {
output stdout
format transform "{common_log}" # log in v1 style, caddyserver/transform-encoder required
}
reverse_proxy docker-registry:80 {
header_up Host {http.reverse_proxy.upstream.hostport}
}
header * x-sjtug-mirror-id zhiyuan
}

google-fonts.mirrors.sjtug.sjtu.edu.cn {
log {
output stdout
Expand Down Expand Up @@ -186,7 +175,6 @@ https://mirrors.sjtug.sjtu.edu.cn {
not path /download.flutter.io/*
not path /k8s.gcr.io/*
not path /registry.k8s.io/*
not path /docker-registry/*
not path /google-fonts/*
not path /anaconda/*
not path /bmclapi/*
Expand Down Expand Up @@ -539,12 +527,6 @@ https://mirrors.sjtug.sjtu.edu.cn {
header_up Host {http.reverse_proxy.upstream.hostport}
}
}
redir /docker-registry /docker-registry/ 301
handle_path /docker-registry/* {
reverse_proxy docker-registry:80 {
header_up Host {http.reverse_proxy.upstream.hostport}
}
}
redir /google-fonts /google-fonts/ 301
handle_path /google-fonts/* {
redir * https://fonts.googleapis.com{uri} 302
Expand Down
12 changes: 6 additions & 6 deletions config.zhiyuan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -307,12 +307,12 @@ repos:
proxy_to: k8s-registry:80
unified: disable
serve_mode: proxy
- type: external
name: docker-registry
proxy_to: docker-registry:80
subdomain: docker.mirrors.sjtug.sjtu.edu.cn
unified: disable
serve_mode: proxy
# - type: external
# name: docker-registry
# proxy_to: docker-registry:80
# subdomain: docker.mirrors.sjtug.sjtu.edu.cn
# unified: disable
# serve_mode: proxy
- type: external
name: google-fonts
subdomain: google-fonts.mirrors.sjtug.sjtu.edu.cn
Expand Down

0 comments on commit eaaec27

Please sign in to comment.