mirror of
https://github.com/casjaysdevdocker/aria2
synced 2025-09-18 09:57:40 -04:00
🗃️ Committing everything that changed 🗃️
Dockerfile .env.scripts .gitattributes .gitea/workflows/docker.yaml .gitignore LICENSE.md README.md rootfs/root/docker/setup/00-init.sh rootfs/root/docker/setup/01-system.sh rootfs/root/docker/setup/02-packages.sh rootfs/root/docker/setup/03-files.sh rootfs/root/docker/setup/04-users.sh rootfs/root/docker/setup/05-custom.sh rootfs/root/docker/setup/06-post.sh rootfs/root/docker/setup/07-cleanup.sh rootfs/tmp/ rootfs/usr/local/bin/entrypoint.sh rootfs/usr/local/bin/pkmgr rootfs/usr/local/etc/docker/env/00-directory.sh rootfs/usr/local/etc/docker/env/addresses.sh rootfs/usr/local/etc/docker/env/certbot.sh rootfs/usr/local/etc/docker/env/couchdb.sh rootfs/usr/local/etc/docker/env/default.sample rootfs/usr/local/etc/docker/env/global.sh rootfs/usr/local/etc/docker/env/healthcheck.sh rootfs/usr/local/etc/docker/env/mariadb.sh rootfs/usr/local/etc/docker/env/mongodb.sh rootfs/usr/local/etc/docker/env/networking.sh rootfs/usr/local/etc/docker/env/other.sh rootfs/usr/local/etc/docker/env/php.sh rootfs/usr/local/etc/docker/env/postgres.sh rootfs/usr/local/etc/docker/env/redis.sh rootfs/usr/local/etc/docker/env/services.sh rootfs/usr/local/etc/docker/env/ssl.sh rootfs/usr/local/etc/docker/env/supabase.sh rootfs/usr/local/etc/docker/env/webservers.sh rootfs/usr/local/etc/docker/env/zz-entrypoint.sh rootfs/usr/local/etc/docker/functions/ rootfs/usr/local/etc/docker/init.d/00-aria2c.sh rootfs/usr/local/etc/docker/init.d/zz-nginx.sh rootfs/usr/local/share/template-files/config/aria2/aria2.conf rootfs/usr/local/share/template-files/config/aria2/aria2.session rootfs/usr/local/share/template-files/config/aria2/aria-ng.config.js rootfs/usr/local/share/template-files/config/aria2/scripts/post-hook.sh rootfs/usr/local/share/template-files/config/env/default.sample rootfs/usr/local/share/template-files/config/env/examples/ rootfs/usr/local/share/template-files/config/.gitkeep rootfs/usr/local/share/template-files/config/nginx/mime.types rootfs/usr/local/share/template-files/config/nginx/nginx.conf
This commit is contained in:
8195
rootfs/tmp/etc/aria2/aria-ng.config.js
Executable file
8195
rootfs/tmp/etc/aria2/aria-ng.config.js
Executable file
File diff suppressed because one or more lines are too long
36
rootfs/tmp/etc/aria2/aria2.conf
Normal file
36
rootfs/tmp/etc/aria2/aria2.conf
Normal file
@@ -0,0 +1,36 @@
|
||||
# Default configuration for aria2
|
||||
dir=/data/downloads/aria2
|
||||
log=/data/logs/aria2/aria2.log
|
||||
input-file=/config/aria2/aria2.session
|
||||
save-session=/config/aria2/aria2.session
|
||||
enable-rpc=true
|
||||
rpc-listen-port=REPLACE_RPC_PORT
|
||||
rpc-allow-origin-all=true
|
||||
rpc-listen-all=true
|
||||
rpc-secret=REPLACE_RPC_SECRET
|
||||
disable-ipv6=true
|
||||
max-concurrent-downloads=5
|
||||
continue=true
|
||||
max-connection-per-server=5
|
||||
min-split-size=10M
|
||||
split=10
|
||||
enable-http-pipelining=true
|
||||
max-overall-download-limit=0
|
||||
max-download-limit=0
|
||||
max-overall-upload-limit=0
|
||||
max-upload-limit=0
|
||||
file-allocation=prealloc
|
||||
console-log-level=error
|
||||
save-session-interval=10
|
||||
max-upload-limit=0
|
||||
|
||||
follow-torrent=true
|
||||
listen-port=6881
|
||||
user-agent=Transmission/2.77
|
||||
seed-ratio=0
|
||||
bt-seed-unverified=false
|
||||
bt-save-metadata=true
|
||||
|
||||
bt-tracker=udp://62.138.0.158:6969/announce,udp://188.241.58.209:6969/announce,udp://151.80.120.112:2710/announce,udp://151.80.120.114:2710/announce,udp://93.158.213.92:1337/announce,udp://185.19.107.254:80/announce,udp://185.225.17.100:1337/announce,udp://208.83.20.20:6969/announce,udp://5.206.19.247:6969/announce,udp://37.235.174.46:2710/announce,udp://142.44.243.4:1337/announce,udp://195.154.52.99:80/announce,udp://54.37.235.149:6969/announce,udp://212.1.226.176:2710/announce,udp://89.234.156.205:451/announce,udp://159.100.245.181:6969/announce,udp://45.56.74.11:6969/announce,udp://51.15.226.113:6969/announce,udp://176.113.71.19:6961/announce,udp://51.15.40.114:80/announce
|
||||
on-download-error=/etc/aria2/scripts/post-hook.sh
|
||||
on-download-complete=/etc/aria2/scripts/post-hook.sh
|
0
rootfs/tmp/etc/aria2/aria2.session
Executable file
0
rootfs/tmp/etc/aria2/aria2.session
Executable file
22
rootfs/tmp/etc/aria2/scripts/post-hook.sh
Executable file
22
rootfs/tmp/etc/aria2/scripts/post-hook.sh
Executable file
@@ -0,0 +1,22 @@
|
||||
#!/usr/bin/env bash
|
||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
##@Version : 202210191942-git
|
||||
# @@Author : Jason Hempstead
|
||||
# @@Contact : git-admin@casjaysdev.pro
|
||||
# @@License : LICENSE.md
|
||||
# @@ReadME : post-hook.sh --help
|
||||
# @@Copyright : Copyright: (c) 2022 Jason Hempstead, Casjays Developments
|
||||
# @@Created : Wednesday, Oct 19, 2022 19:42 EDT
|
||||
# @@File : post-hook.sh
|
||||
# @@Description : post script
|
||||
# @@Changelog : newScript
|
||||
# @@TODO : Refactor code
|
||||
# @@Other :
|
||||
# @@Resource : https://aria2.github.io/manual/en/html/aria2c.html#event-hook
|
||||
# @@Terminal App : no
|
||||
# @@sudo/root : no
|
||||
# @@Template : bash/system
|
||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
set -eu
|
||||
|
||||
echo "[INFO] $(date -u +'%Y-%m-%dT%H:%M:%SZ') Aria2 hook triggered with parameters: GID [$1], Files Count: [$2], Files Path: [$3]"
|
99
rootfs/tmp/etc/nginx/mime.types
Normal file
99
rootfs/tmp/etc/nginx/mime.types
Normal file
@@ -0,0 +1,99 @@
|
||||
|
||||
types {
|
||||
text/html html htm shtml;
|
||||
text/css css;
|
||||
text/xml xml;
|
||||
image/gif gif;
|
||||
image/jpeg jpeg jpg;
|
||||
application/javascript js;
|
||||
application/atom+xml atom;
|
||||
application/rss+xml rss;
|
||||
|
||||
text/mathml mml;
|
||||
text/plain txt;
|
||||
text/vnd.sun.j2me.app-descriptor jad;
|
||||
text/vnd.wap.wml wml;
|
||||
text/x-component htc;
|
||||
|
||||
image/avif avif;
|
||||
image/png png;
|
||||
image/svg+xml svg svgz;
|
||||
image/tiff tif tiff;
|
||||
image/vnd.wap.wbmp wbmp;
|
||||
image/webp webp;
|
||||
image/x-icon ico;
|
||||
image/x-jng jng;
|
||||
image/x-ms-bmp bmp;
|
||||
|
||||
font/woff woff;
|
||||
font/woff2 woff2;
|
||||
|
||||
application/java-archive jar war ear;
|
||||
application/json json;
|
||||
application/mac-binhex40 hqx;
|
||||
application/msword doc;
|
||||
application/pdf pdf;
|
||||
application/postscript ps eps ai;
|
||||
application/rtf rtf;
|
||||
application/vnd.apple.mpegurl m3u8;
|
||||
application/vnd.google-earth.kml+xml kml;
|
||||
application/vnd.google-earth.kmz kmz;
|
||||
application/vnd.ms-excel xls;
|
||||
application/vnd.ms-fontobject eot;
|
||||
application/vnd.ms-powerpoint ppt;
|
||||
application/vnd.oasis.opendocument.graphics odg;
|
||||
application/vnd.oasis.opendocument.presentation odp;
|
||||
application/vnd.oasis.opendocument.spreadsheet ods;
|
||||
application/vnd.oasis.opendocument.text odt;
|
||||
application/vnd.openxmlformats-officedocument.presentationml.presentation
|
||||
pptx;
|
||||
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
|
||||
xlsx;
|
||||
application/vnd.openxmlformats-officedocument.wordprocessingml.document
|
||||
docx;
|
||||
application/vnd.wap.wmlc wmlc;
|
||||
application/wasm wasm;
|
||||
application/x-7z-compressed 7z;
|
||||
application/x-cocoa cco;
|
||||
application/x-java-archive-diff jardiff;
|
||||
application/x-java-jnlp-file jnlp;
|
||||
application/x-makeself run;
|
||||
application/x-perl pl pm;
|
||||
application/x-pilot prc pdb;
|
||||
application/x-rar-compressed rar;
|
||||
application/x-redhat-package-manager rpm;
|
||||
application/x-sea sea;
|
||||
application/x-shockwave-flash swf;
|
||||
application/x-stuffit sit;
|
||||
application/x-tcl tcl tk;
|
||||
application/x-x509-ca-cert der pem crt;
|
||||
application/x-xpinstall xpi;
|
||||
application/xhtml+xml xhtml;
|
||||
application/xspf+xml xspf;
|
||||
application/zip zip;
|
||||
|
||||
application/octet-stream bin exe dll;
|
||||
application/octet-stream deb;
|
||||
application/octet-stream dmg;
|
||||
application/octet-stream iso img;
|
||||
application/octet-stream msi msp msm;
|
||||
|
||||
audio/midi mid midi kar;
|
||||
audio/mpeg mp3;
|
||||
audio/ogg ogg;
|
||||
audio/x-m4a m4a;
|
||||
audio/x-realaudio ra;
|
||||
|
||||
video/3gpp 3gpp 3gp;
|
||||
video/mp2t ts;
|
||||
video/mp4 mp4;
|
||||
video/mpeg mpeg mpg;
|
||||
video/quicktime mov;
|
||||
video/webm webm;
|
||||
video/x-flv flv;
|
||||
video/x-m4v m4v;
|
||||
video/x-mng mng;
|
||||
video/x-ms-asf asx asf;
|
||||
video/x-ms-wmv wmv;
|
||||
video/x-msvideo avi;
|
||||
}
|
83
rootfs/tmp/etc/nginx/nginx.conf
Normal file
83
rootfs/tmp/etc/nginx/nginx.conf
Normal file
@@ -0,0 +1,83 @@
|
||||
# Default nginx configuration
|
||||
user root;
|
||||
worker_processes auto;
|
||||
daemon off;
|
||||
|
||||
error_log /data/logs/nginx/nginx.log error;
|
||||
pid /var/run/nginx.pid;
|
||||
|
||||
events {
|
||||
worker_connections 1024;
|
||||
}
|
||||
|
||||
http {
|
||||
include /etc/nginx/mime.types;
|
||||
default_type application/octet-stream;
|
||||
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||
'$status $body_bytes_sent "$http_referer" '
|
||||
'"$http_user_agent" "$http_x_forwarded_for"';
|
||||
access_log /data/logs/nginx/access.log main;
|
||||
sendfile on;
|
||||
keepalive_timeout 65;
|
||||
gzip on;
|
||||
map $http_upgrade $connection_upgrade { default upgrade; '' close; }
|
||||
disable_symlinks off;
|
||||
|
||||
server {
|
||||
listen REPLACE_SERVER_PORT;
|
||||
root /usr/local/share/ariang;
|
||||
index index.html;
|
||||
proxy_intercept_errors off;
|
||||
add_header X-Frame-Options "SAMEORIGIN" always;
|
||||
add_header X-XSS-Protection "1; mode=block" always;
|
||||
add_header X-Content-Type-Options "nosniff" always;
|
||||
add_header Referrer-Policy "no-referrer-when-downgrade" always;
|
||||
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains" always;
|
||||
add_header Content-Security-Policy "script-src 'self' 'unsafe-inline' 'unsafe-eval' *; frame-src 'self' *; object-src 'self'" always;
|
||||
|
||||
location /jsonrpc {
|
||||
proxy_pass http://127.0.0.1:6800/jsonrpc;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_read_timeout 86400;
|
||||
}
|
||||
|
||||
location /rpc {
|
||||
proxy_pass http://127.0.0.1:6800/jsonrpc;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_read_timeout 86400;
|
||||
}
|
||||
|
||||
location = /favicon.ico {
|
||||
log_not_found off;
|
||||
access_log off;
|
||||
}
|
||||
|
||||
location = /robots.txt {
|
||||
allow all;
|
||||
log_not_found off;
|
||||
access_log off;
|
||||
}
|
||||
|
||||
location /nginx_status {
|
||||
stub_status;
|
||||
}
|
||||
|
||||
location /health {
|
||||
default_type text/html;
|
||||
allow all;
|
||||
access_log off;
|
||||
return 200 'OK';
|
||||
}
|
||||
|
||||
location /health/json {
|
||||
default_type application/json;
|
||||
allow all;
|
||||
access_log off;
|
||||
return 200 '{"status":"OK"}';
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user