Skip to content

Commit a02b76b

Browse files
lug: ubuntu-releases (#490)
1 parent 91df382 commit a02b76b

File tree

3 files changed

+22
-8
lines changed

3 files changed

+22
-8
lines changed

caddy/Caddyfile.siyuan

+9
Original file line numberDiff line numberDiff line change
@@ -529,6 +529,15 @@ https://mirror.sjtu.edu.cn {
529529
@hidden path */.*
530530
respond @hidden 404
531531
}
532+
redir /ubuntu-releases /ubuntu-releases/ 301
533+
handle /ubuntu-releases/* {
534+
file_server browse {
535+
root /srv/data32T
536+
hide .*
537+
}
538+
@hidden path */.*
539+
respond @hidden 404
540+
}
532541
redir /ubuntu-cdimage /ubuntu-cdimage/ 301
533542
handle /ubuntu-cdimage/* {
534543
file_server browse {

caddy/Caddyfile.zhiyuan

+5
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@ https://mirrors.sjtug.sjtu.edu.cn {
213213
not path /remi/*
214214
not path /termux/*
215215
not path /ubuntu/*
216+
not path /ubuntu-releases/*
216217
not path /ubuntu-cdimage/*
217218
not path /ubuntu-ports/*
218219
not path /openwrt/*
@@ -716,6 +717,10 @@ https://mirrors.sjtug.sjtu.edu.cn {
716717
handle_path /ubuntu/* {
717718
redir * https://mirror.sjtu.edu.cn/ubuntu{uri} 302
718719
}
720+
redir /ubuntu-releases /ubuntu-releases/ 301
721+
handle_path /ubuntu-releases/* {
722+
redir * https://mirror.sjtu.edu.cn/ubuntu-releases{uri} 302
723+
}
719724
redir /ubuntu-cdimage /ubuntu-cdimage/ 301
720725
handle_path /ubuntu-cdimage/* {
721726
redir * https://mirror.sjtu.edu.cn/ubuntu-cdimage{uri} 302

config.siyuan.yaml

+8-8
Original file line numberDiff line numberDiff line change
@@ -397,14 +397,14 @@ repos:
397397
name: ubuntu
398398
no_redir_http: true
399399
<<: *oneshot_common
400-
# # ubuntu-cd
401-
# - type: shell_script
402-
# script: /worker-script/rsync.sh
403-
# source: rsync://rsync.releases.ubuntu.com/releases/
404-
# interval: 24600
405-
# path: /srv/data32T/ubuntu-cd
406-
# name: ubuntu-cd
407-
# <<: *oneshot_common
400+
# ubuntu-releases
401+
- type: shell_script
402+
script: /worker-script/rsync.sh
403+
source: rsync://rsync.releases.ubuntu.com/releases/
404+
interval: 24600
405+
path: /srv/data32T/ubuntu-releases
406+
name: ubuntu-releases
407+
<<: *oneshot_common
408408
# ubuntu-cdimage
409409
- type: shell_script
410410
script: /worker-script/rsync.sh

0 commit comments

Comments
 (0)