From 76def50a685f584fcb0c46c1bf61166f11f93471 Mon Sep 17 00:00:00 2001 From: admin_rb Date: Sun, 21 Dec 2025 18:10:43 +0100 Subject: [PATCH] chmod --- .gitignore | 0 LICENSE | 0 README.md | 0 controllers/pm2Controller.js | 0 controllers/queueController.js | 0 lib/mongo.js | 0 package-lock.json | 0 package.json | 0 public/assets/favicon.ico | Bin public/style.css | 0 queue_worker.js | 4 ++-- requirements.txt | Bin routes/index.js | 2 +- .../__pycache__/proxer_utils.cpython-311.pyc | Bin .../__pycache__/proxer_utils.cpython-313.pyc | Bin 5932 -> 5947 bytes .../__pycache__/proxer_utils.cpython-38.pyc | Bin .../__pycache__/script_utils.cpython-313.pyc | Bin .../__pycache__/script_utils.cpython-38.pyc | Bin scripts/lib/proxer_utils.py | 5 +++++ scripts/lib/script_utils.py | 0 scripts/proxer-dl-series.py | 0 scripts/proxer-dl-video.py | 0 scripts/requirements.txt | Bin server.js | 0 views/error.ejs | 0 views/index.ejs | 0 views/partials/footer.ejs | 0 views/partials/header.ejs | 0 views/pm2.ejs | 0 views/status.ejs | 0 30 files changed, 8 insertions(+), 3 deletions(-) mode change 100644 => 100755 .gitignore mode change 100644 => 100755 LICENSE mode change 100644 => 100755 README.md mode change 100644 => 100755 controllers/pm2Controller.js mode change 100644 => 100755 controllers/queueController.js mode change 100644 => 100755 lib/mongo.js mode change 100644 => 100755 package-lock.json mode change 100644 => 100755 package.json mode change 100644 => 100755 public/assets/favicon.ico mode change 100644 => 100755 public/style.css mode change 100644 => 100755 queue_worker.js mode change 100644 => 100755 requirements.txt mode change 100644 => 100755 routes/index.js mode change 100644 => 100755 scripts/lib/__pycache__/proxer_utils.cpython-311.pyc mode change 100644 => 100755 scripts/lib/__pycache__/proxer_utils.cpython-313.pyc mode change 100644 => 100755 scripts/lib/__pycache__/proxer_utils.cpython-38.pyc mode change 100644 => 100755 scripts/lib/__pycache__/script_utils.cpython-313.pyc mode change 100644 => 100755 scripts/lib/__pycache__/script_utils.cpython-38.pyc mode change 100644 => 100755 scripts/lib/proxer_utils.py mode change 100644 => 100755 scripts/lib/script_utils.py mode change 100644 => 100755 scripts/proxer-dl-series.py mode change 100644 => 100755 scripts/proxer-dl-video.py mode change 100644 => 100755 scripts/requirements.txt mode change 100644 => 100755 server.js mode change 100644 => 100755 views/error.ejs mode change 100644 => 100755 views/index.ejs mode change 100644 => 100755 views/partials/footer.ejs mode change 100644 => 100755 views/partials/header.ejs mode change 100644 => 100755 views/pm2.ejs mode change 100644 => 100755 views/status.ejs diff --git a/.gitignore b/.gitignore old mode 100644 new mode 100755 diff --git a/LICENSE b/LICENSE old mode 100644 new mode 100755 diff --git a/README.md b/README.md old mode 100644 new mode 100755 diff --git a/controllers/pm2Controller.js b/controllers/pm2Controller.js old mode 100644 new mode 100755 diff --git a/controllers/queueController.js b/controllers/queueController.js old mode 100644 new mode 100755 diff --git a/lib/mongo.js b/lib/mongo.js old mode 100644 new mode 100755 diff --git a/package-lock.json b/package-lock.json old mode 100644 new mode 100755 diff --git a/package.json b/package.json old mode 100644 new mode 100755 diff --git a/public/assets/favicon.ico b/public/assets/favicon.ico old mode 100644 new mode 100755 diff --git a/public/style.css b/public/style.css old mode 100644 new mode 100755 diff --git a/queue_worker.js b/queue_worker.js old mode 100644 new mode 100755 index 326ff13..db839fc --- a/queue_worker.js +++ b/queue_worker.js @@ -10,7 +10,7 @@ require("dotenv").config(); // ======================== const MONGO_URI = process.env.MONGO_URI; const DB_NAME = process.env.MONGO_DB || "downloads"; -const OUTPUT_DIR = process.env.OUTPUT_DIR || "/mnt/media/WIP/"; +const OUTPUT_DIR = process.env.OUTPUT_DIR || "/mnt/media/WIP"; const client = new MongoClient(MONGO_URI); let queueCol, doneCol, failedCol; @@ -41,7 +41,7 @@ async function runJob(job) { "-t", job.token, "-o", - process.env.OUTPUT_DIR, + OUTPUT_DIR, ]; const proc = spawn(cmd[0], cmd.slice(1)); diff --git a/requirements.txt b/requirements.txt old mode 100644 new mode 100755 diff --git a/routes/index.js b/routes/index.js old mode 100644 new mode 100755 index c4ed637..d480647 --- a/routes/index.js +++ b/routes/index.js @@ -73,7 +73,7 @@ router.post("/clear-queued", async (req, res) => { const db = await getDb(); await db .collection("queue") - .deleteMany({}) //delete all + .deleteMany({ processing: { $ne: 1 } }) //delete all // Redirect to status, controller fetches everything res.redirect("/status"); diff --git a/scripts/lib/__pycache__/proxer_utils.cpython-311.pyc b/scripts/lib/__pycache__/proxer_utils.cpython-311.pyc old mode 100644 new mode 100755 diff --git a/scripts/lib/__pycache__/proxer_utils.cpython-313.pyc b/scripts/lib/__pycache__/proxer_utils.cpython-313.pyc old mode 100644 new mode 100755 index 9f84a821a77393c81be572504672ddca228b335f..5c00962579993adc5fdbd2d66444ccb91496afa1 GIT binary patch delta 510 zcmYk3!Al!K6vp4%osFAqvYTvn*O*!x6RWqJ)=Lo&y;yb+6$hc{whfIU21S_ATdM(& zo@5ZDe}H)Cp|H@49)$h{UOZSrPd)S&k@oDH6~ux0zInfIn0d^6Yn`?1+hWlI8YeTa zH{X;F?P}COfFs}_fFsvp6qvatG;%%GBPLi~Wh^$LoXABZVk9z!nK2{IN0zYakl<1v z+hvc@qI%eWvBze0bq|0jR-pmhssVqJ*bmgnXn|-kaUN(Xqc&0J5iRpl;_`A*N!-K@ zHG@v&YL(-a8g!ZPxJS7njQbh!CwPqq1V?FBRmio_^GV%_v zB(J=Ed@fh~Cfah>f9Z^hKs~}+l51_JCx80=SnU^OCF4q-smz?)-dX#!wLUMpRMMY7 z@0?_)BjOEp$!-gP&M(Lh!2b>5C4>W*9GdbV_%hYR@VGeyveSF}-pQ(q@V|oDEqCi- BXx#t+ delta 467 zcmYk2&nrYx6vxkb@4oqE=FJc9J!AanF(YMR^=xdEV)169xrum96A^>x+7hLttfrfi zrIm%GUMbnwTgcL4_zToXSy9e=N^afn_ngnSPN#D>d^xOtq*4i>_b}$Hex)0Fe!PGH zC%{1fN3N7nAh}vrTve!cz*w2Nn$X;ch`3P^4VhMsxp5JyLcon-UaEzj8; z={Kn@XSHdx{VVN;VaZ=g#2HTboB9q@#GwC{tD#nvf#6>90$uzgF?QW5c;Henx0z;qMLS8$%dX+mEsBG0Vdl8w%3 Vu?1uozjnPCcK6O_07W-V`2h|XU#$QD diff --git a/scripts/lib/__pycache__/proxer_utils.cpython-38.pyc b/scripts/lib/__pycache__/proxer_utils.cpython-38.pyc old mode 100644 new mode 100755 diff --git a/scripts/lib/__pycache__/script_utils.cpython-313.pyc b/scripts/lib/__pycache__/script_utils.cpython-313.pyc old mode 100644 new mode 100755 diff --git a/scripts/lib/__pycache__/script_utils.cpython-38.pyc b/scripts/lib/__pycache__/script_utils.cpython-38.pyc old mode 100644 new mode 100755 diff --git a/scripts/lib/proxer_utils.py b/scripts/lib/proxer_utils.py old mode 100644 new mode 100755 index 3973325..88497fe --- a/scripts/lib/proxer_utils.py +++ b/scripts/lib/proxer_utils.py @@ -5,10 +5,12 @@ """ import logging +import os from enum import Enum from requests import Response, get, RequestException from clint.textui import progress + # Set up logging logging.basicConfig(level=logging.INFO, format="%(levelname)s: %(message)s") @@ -116,6 +118,9 @@ def download_mp4(mp4_url: str, save_path: str, label: str = "") -> None: except RequestException as e: raise NetworkError(f"Failed to start download: {e}") + # Prepare save path + #os.makedirs(save_path, exist_ok=True) + # Download file with progress bar with open(save_path, "wb") as file: if total_length: diff --git a/scripts/lib/script_utils.py b/scripts/lib/script_utils.py old mode 100644 new mode 100755 diff --git a/scripts/proxer-dl-series.py b/scripts/proxer-dl-series.py old mode 100644 new mode 100755 diff --git a/scripts/proxer-dl-video.py b/scripts/proxer-dl-video.py old mode 100644 new mode 100755 diff --git a/scripts/requirements.txt b/scripts/requirements.txt old mode 100644 new mode 100755 diff --git a/server.js b/server.js old mode 100644 new mode 100755 diff --git a/views/error.ejs b/views/error.ejs old mode 100644 new mode 100755 diff --git a/views/index.ejs b/views/index.ejs old mode 100644 new mode 100755 diff --git a/views/partials/footer.ejs b/views/partials/footer.ejs old mode 100644 new mode 100755 diff --git a/views/partials/header.ejs b/views/partials/header.ejs old mode 100644 new mode 100755 diff --git a/views/pm2.ejs b/views/pm2.ejs old mode 100644 new mode 100755 diff --git a/views/status.ejs b/views/status.ejs old mode 100644 new mode 100755