mirror of
https://github.com/wahyd4/aria2-ariang-docker.git
synced 2026-08-08 21:05:50 +10:00
Make sure /ro and other resources are protected (#248)
This commit is contained in:
+12
-1
@@ -5,7 +5,9 @@
|
||||
|
||||
:PORT
|
||||
|
||||
basicauth / {
|
||||
@protected path / /index.html /css/* /js/* /ro /ro/* /jsonrpc
|
||||
|
||||
basicauth @protected {
|
||||
ARIA2_USER ARIA2_PWD_ENCRYPT
|
||||
}
|
||||
|
||||
@@ -13,6 +15,7 @@ redir /ui / 301
|
||||
redir /ui/ / 301
|
||||
redir /rclone /rclone/ 301
|
||||
redir /files /files/ 301
|
||||
redir /ro /ro/ 301
|
||||
|
||||
reverse_proxy /jsonrpc 127.0.0.1:6800
|
||||
|
||||
@@ -26,6 +29,14 @@ route /files/* {
|
||||
reverse_proxy 127.0.0.1:8080
|
||||
}
|
||||
|
||||
route /ro/* {
|
||||
uri strip_prefix /ro
|
||||
root * /data
|
||||
file_server {
|
||||
browse "{$CADDY_FILE_SERVER_BROWSE_HTML}"
|
||||
}
|
||||
}
|
||||
|
||||
route /ping {
|
||||
respond "app version: {env.APP_VERSION}"
|
||||
}
|
||||
|
||||
+4
-1
@@ -5,7 +5,9 @@ log {
|
||||
output stderr
|
||||
}
|
||||
|
||||
basicauth / {
|
||||
@protected path / /index.html /css/* /js/* /ro /ro/* /jsonrpc
|
||||
|
||||
basicauth @protected {
|
||||
ARIA2_USER ARIA2_PWD_ENCRYPT
|
||||
}
|
||||
|
||||
@@ -13,6 +15,7 @@ redir /ui / 301
|
||||
redir /ui/ / 301
|
||||
redir /rclone /rclone/ 301
|
||||
redir /files /files/ 301
|
||||
redir /ro /ro/ 301
|
||||
|
||||
reverse_proxy /rpc 127.0.0.1:6800
|
||||
reverse_proxy /jsonrpc 127.0.0.1:6800
|
||||
|
||||
Reference in New Issue
Block a user