From 48706bd0751f0926a6e003578789d84acfbe5bf2 Mon Sep 17 00:00:00 2001 From: voc0der Date: Thu, 26 Feb 2026 07:05:30 -0500 Subject: [PATCH] Refresh docs and Docker Compose defaults --- .../workflows/close-issue-if-noresponse.yml | 2 +- .github/workflows/docker.yml | 2 +- Dockerfile.heroku | 2 +- Public API v1.yaml | 2 +- README.md | 67 +++++++++---------- SECURITY.md | 2 +- app.json | 2 +- backend/app.js | 8 +-- backend/authentication/auth.js | 2 +- chart/Chart.yaml | 2 +- chart/values.yaml | 2 +- docker-compose.yml | 17 ++++- src/app/posts.services.ts | 4 +- src/app/settings/settings.component.html | 8 +-- 14 files changed, 64 insertions(+), 58 deletions(-) diff --git a/.github/workflows/close-issue-if-noresponse.yml b/.github/workflows/close-issue-if-noresponse.yml index 64d4756..e7cb224 100644 --- a/.github/workflows/close-issue-if-noresponse.yml +++ b/.github/workflows/close-issue-if-noresponse.yml @@ -17,7 +17,7 @@ permissions: jobs: noResponse: runs-on: ubuntu-latest - if: ${{ github.repository == 'Tzahi12345/YoutubeDL-Material' }} + if: ${{ github.repository == 'voc0der/YoutubeDL-Material' }} steps: - uses: lee-dohm/no-response@v0.5.0 with: diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index d8a7bb1..982f966 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -53,7 +53,7 @@ jobs: id: docker-meta uses: docker/metadata-action@v5 # Defaults: - # DOCKERHUB_USERNAME : tzahi12345 + # DOCKERHUB_USERNAME : voc0der # DOCKERHUB_REPO : youtubedl-material # DOCKERHUB_MASTER_TAG: nightly with: diff --git a/Dockerfile.heroku b/Dockerfile.heroku index 977a446..fed95fe 100644 --- a/Dockerfile.heroku +++ b/Dockerfile.heroku @@ -1,2 +1,2 @@ -FROM tzahi12345/youtubedl-material:latest +FROM voc0der/youtubedl-material:latest CMD [ "npm", "start" ] \ No newline at end of file diff --git a/Public API v1.yaml b/Public API v1.yaml index 9682671..80af1dd 100644 --- a/Public API v1.yaml +++ b/Public API v1.yaml @@ -5,7 +5,7 @@ info: description: "Welcome to the official docs for YoutubeDL-Material.\n\n\nYou can check out all the available endpoints. Remember to authenticate with your API key using the \"apiKey\" query parameter with your requests.\n\n\nTo do so, simply add this to the end of your API call:\n\n\n`?apiKey=API_KEY`\n\n\nReplce API_KEY with the API key in the settings menu. If one doesn't exist, click generate to create one.\n\n### Multi-user mode\n\nWhen using multi-user mode, you will need to supply a JWT token to authenticate requests through that user. This lets the server know which user to run the task for, like downloading a video for a specific user. \n\nTo do this, you must use the `/api/auth/login` endpoint to login using a user's username and password. This will result in an object containing a `token`. Supply this along with your API key like so:\n\n`?apiKey=API_KEY&jwt=JWT_TOKEN`\n\nNotice the `&` between the `API_KEY` and `jwt`." contact: name: Isaac Abadi - url: https://github.com/Tzahi12345/YoutubeDL-Material + url: https://github.com/voc0der/YoutubeDL-Material email: IsaacMGrynsztein@gmail.com servers: - url: 'http://localhost:17442' diff --git a/README.md b/README.md index bc17776..eae610c 100644 --- a/README.md +++ b/README.md @@ -4,14 +4,11 @@ [![Docker pulls badge](https://img.shields.io/docker/pulls/voc0der/youtubedl-material.svg)](https://hub.docker.com/r/voc0der/youtubedl-material) [![Docker image size badge](https://img.shields.io/docker/image-size/voc0der/youtubedl-material?sort=date)](https://hub.docker.com/r/voc0der/youtubedl-material) -[![Heroku deploy badge](https://img.shields.io/badge/%E2%86%91_Deploy_to-Heroku-7056bf.svg)](https://heroku.com/deploy?template=https://github.com/voc0der/YoutubeDL-Material) [![GitHub issues badge](https://img.shields.io/github/issues/voc0der/YoutubeDL-Material)](https://github.com/voc0der/YoutubeDL-Material/issues) [![License badge](https://img.shields.io/github/license/voc0der/YoutubeDL-Material)](https://github.com/voc0der/YoutubeDL-Material/blob/master/LICENSE.md) YoutubeDL-Material is a Material Design frontend for [youtube-dl](https://rg3.github.io/youtube-dl/) / yt-dlp workflows. It's coded using [Angular 21](https://angular.dev/) for the frontend, and [Node.js](https://nodejs.org/) on the backend. -Now with [Docker](#Docker) support! -
## Getting Started @@ -52,13 +49,6 @@ python3 -m pip install --user yt-dlp yt-dlp-ejs -
- CentOS 7 (legacy) - -Current builds require Node.js 24 (`>=24 <26`), so CentOS 7 is no longer a supported host for native installs. Use Docker or a newer distro. - -
- ### Installing If you are using Docker, skip to the [Docker](#Docker) section. Otherwise, continue: @@ -111,13 +101,16 @@ The repo currently uses Angular 21 and `@videogular/ngx-videogular@20`. Videogul Please keep this file when building locally or in Docker until Videogular publishes Angular 21 peer support. -Lastly, type `npm -g install pm2` to install pm2 globally. +### Run backend -The frontend is now complete. The backend is much easier. Just go into the `backend` folder, and type `npm start`. +Install `pm2` globally, then start the backend: -Finally, if you want your instance to be available from outside your network, you can set up a [reverse proxy](https://github.com/voc0der/YoutubeDL-Material/wiki/Reverse-Proxy-Setup). +```bash +npm -g install pm2 +npm start --prefix backend +``` -Alternatively, you can port forward the port specified in the config (defaults to `17442`) and point it to the server's IP address. Make sure the port is also allowed through the server's firewall. +If you want your instance available outside your network, set up a [reverse proxy](https://github.com/voc0der/YoutubeDL-Material/wiki/Reverse-Proxy-Setup) or port forward the configured backend port (default `17442`). ## Docker @@ -136,31 +129,39 @@ If you are looking to setup YoutubeDL-Material with Docker, this section is for 3. Run `docker compose up -d` (or `docker-compose up -d`) to start it up. The container exposes port `17442` internally. Please check your `docker-compose.yml` file for the *external* port. If you downloaded the file as described above, it defaults to **8998**. 4. Make sure you can connect to the specified URL + *external* port, and if so, you are done! -### Custom UID/GID - -By default, the Docker container runs as non-root with UID=1000 and GID=1000. To set this to your own UID/GID, simply update the `environment` section in your `docker-compose.yml` like so: - -```yml -environment: - UID: YOUR_UID - GID: YOUR_GID -``` - -### Logging +
+ Docker environment variables (click to expand) -You can control backend log verbosity with the `YTDL_LOG_LEVEL` environment variable (or `ytdl_log_level`). +Common Docker env vars used by the provided `docker-compose.yml` (plus logging): -- Default: `info` (mostly startup messages, warnings, and errors) -- Use `debug` to enable verbose yt-dlp/debug diagnostics -- Supported values follow standard Winston levels (for example: `error`, `warn`, `info`, `verbose`, `debug`) +- `ytdl_mongodb_connection_string`: MongoDB connection string (default compose file points to `mongodb://ytdl-mongo-db:27017`) +- `ytdl_use_local_db`: set to `'false'` to use MongoDB instead of the local JSON DB +- `write_ytdl_config`: set to `'true'` to write env-backed settings into `appdata/default.json` on startup +- `UID` / `GID`: set the app user/group IDs used inside the container (default behavior drops to `1000:1000`) +- `YTDL_LOG_LEVEL` (or `ytdl_log_level`): backend log level, default `info` +- Valid log levels: `error`, `warn`, `info`, `verbose`, `debug` +- `ytdl_ssl_cert_path` / `ytdl_ssl_key_path`: enable HTTPS by pointing to mounted cert/key files +- `ytdl_reverse_proxy_whitelist`: comma-separated CIDR ranges allowed to connect (reverse proxy IPs, not client IPs) Example Docker Compose snippet: ```yml environment: - YTDL_LOG_LEVEL: debug + ytdl_mongodb_connection_string: 'mongodb://ytdl-mongo-db:27017' + ytdl_use_local_db: 'false' + write_ytdl_config: 'true' + # UID: 1000 + # GID: 1000 + # YTDL_LOG_LEVEL: debug + # ytdl_ssl_cert_path: /mnt/keys/fullchain.pem + # ytdl_ssl_key_path: /mnt/keys/privkey.pem + # ytdl_reverse_proxy_whitelist: 172.28.0.100/32 ``` +If you prefer, you can also use Docker's `user: "UID:GID"` setting instead of `UID`/`GID`. + +
+ ## MongoDB For much better scaling with large datasets please run your YoutubeDL-Material instance with MongoDB backend rather than the json file-based default. It will fix a lot of performance problems (especially with datasets in the tens of thousands videos/audios)! @@ -175,12 +176,6 @@ To get started, go to the settings menu and enable the public API from the *Extr Once you have enabled the API and have the key, you can start sending requests by adding the query param `apiKey=API_KEY`. Replace `API_KEY` with your actual API key, and you should be good to go! Nearly all of the backend should be at your disposal. View available endpoints in the link above. -## iOS Shortcut - -If you are using iOS, try YoutubeDL-Material more conveniently with a Shortcut. With this Shorcut, you can easily start downloading YouTube video with just two taps! (Or maybe three?) - -You can download Shortcut [here.](https://routinehub.co/shortcut/10283/) - ## Contributing If you're interested in contributing, first: awesome! Second, please refer to the guidelines/setup information located in the [Contributing](https://github.com/voc0der/YoutubeDL-Material/wiki/Contributing) wiki page, it's a helpful way to get you on your feet and coding away. diff --git a/SECURITY.md b/SECURITY.md index 0601c7a..0642f58 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -4,7 +4,7 @@ If you would like to see the latest updates, use the `nightly` tag on Docker. -If you'd like to stick with more stable releases, use the `latest` tag on Docker or download the [latest release here](https://github.com/Tzahi12345/YoutubeDL-Material/releases/latest). +If you'd like to stick with more stable releases, use the `latest` tag on Docker or download the [latest release here](https://github.com/voc0der/YoutubeDL-Material/releases/latest). | Version | Supported | | -------------------- | ------------------ | diff --git a/app.json b/app.json index 30a7d86..1512d9b 100644 --- a/app.json +++ b/app.json @@ -1,7 +1,7 @@ { "name": "YoutubeDL-Material", "description": "An open-source and self-hosted YouTube downloader based on Google's Material Design specifications.", - "repository": "https://github.com/Tzahi12345/YoutubeDL-Material", + "repository": "https://github.com/voc0der/YoutubeDL-Material", "stack": "container", "logo": "https://i.imgur.com/GPzvPiU.png", "keywords": ["youtube-dl", "youtubedl-material", "nodejs"] diff --git a/backend/app.js b/backend/app.js index 58ee158..ddc858e 100644 --- a/backend/app.js +++ b/backend/app.js @@ -507,7 +507,7 @@ async function downloadReleaseZip(tag) { // get name of zip file, which depends on the version const tag_without_v = safeTag.substring(1, safeTag.length); const zip_file_name = `youtubedl-material-${tag_without_v}.zip`; - const latest_zip_link = `https://github.com/Tzahi12345/YoutubeDL-Material/releases/download/${encodeURIComponent(safeTag)}/${encodeURIComponent(zip_file_name)}`; + const latest_zip_link = `https://github.com/voc0der/YoutubeDL-Material/releases/download/${encodeURIComponent(safeTag)}/${encodeURIComponent(zip_file_name)}`; // download zip from release const res = await fetch(latest_zip_link); @@ -580,7 +580,7 @@ async function isNewVersionAvailable() { } async function getLatestVersion() { - const res = await fetch('https://api.github.com/repos/tzahi12345/youtubedl-material/releases/latest', {method: 'Get'}); + const res = await fetch('https://api.github.com/repos/voc0der/youtubedl-material/releases/latest', {method: 'Get'}); const json = await res.json(); if (json['message']) { @@ -2557,8 +2557,8 @@ app.get('/api/rss', async function (req, res) { description: 'YoutubeDL-Material downloads', id: utils.getBaseURL(), link: utils.getBaseURL(), - image: 'https://github.com/Tzahi12345/YoutubeDL-Material/blob/master/src/assets/images/logo_128px.png', - favicon: 'https://raw.githubusercontent.com/Tzahi12345/YoutubeDL-Material/master/src/favicon.ico', + image: 'https://github.com/voc0der/YoutubeDL-Material/blob/master/src/assets/images/logo_128px.png', + favicon: 'https://raw.githubusercontent.com/voc0der/YoutubeDL-Material/master/src/favicon.ico', generator: 'YoutubeDL-Material' }); diff --git a/backend/authentication/auth.js b/backend/authentication/auth.js index f0a60fd..5838971 100644 --- a/backend/authentication/auth.js +++ b/backend/authentication/auth.js @@ -33,7 +33,7 @@ exports.initialize = function () { }); } - // Sometimes this value is not properly typed: https://github.com/Tzahi12345/YoutubeDL-Material/issues/813 + // Sometimes this value is not properly typed: https://github.com/voc0der/YoutubeDL-Material/issues/813 JWT_EXPIRATION = config_api.getConfigItem('ytdl_jwt_expiration'); if (!(+JWT_EXPIRATION)) { logger.warn(`JWT expiration value improperly set to ${JWT_EXPIRATION}, auto setting to 1 day.`); diff --git a/chart/Chart.yaml b/chart/Chart.yaml index 607a12f..4f91d1b 100644 --- a/chart/Chart.yaml +++ b/chart/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: youtubedl-material -description: A Helm chart for https://github.com/Tzahi12345/YoutubeDL-Material +description: A Helm chart for https://github.com/voc0der/YoutubeDL-Material # A chart can be either an 'application' or a 'library' chart. # diff --git a/chart/values.yaml b/chart/values.yaml index b192e16..fe7d252 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -5,7 +5,7 @@ replicaCount: 1 image: - repository: tzahi12345/youtubedl-material + repository: voc0der/youtubedl-material pullPolicy: IfNotPresent # Overrides the image tag whose default is the chart appVersion. tag: "" diff --git a/docker-compose.yml b/docker-compose.yml index 9018016..cf2d101 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -14,6 +14,9 @@ services: # ytdl_ssl_cert_path: /mnt/keys/bindable-internal/lurker/fullchain-or-ca.pem # ytdl_ssl_key_path: /mnt/keys/bindable-internal/lurker/privkey.pem + # Backend log level (optional): error, warn, info, verbose, debug + # YTDL_LOG_LEVEL: info + # Reverse Proxy Whitelist (optional) # Whitelists the reverse proxy's IP (the direct connecting IP, not end clients) # This checks which reverse proxy is allowed to connect, not client IPs @@ -27,7 +30,8 @@ services: # user: "1000:1000" restart: always depends_on: - - ytdl-mongo-db + ytdl-mongo-db: + condition: service_healthy volumes: - ./appdata:/app/appdata - ./audio:/app/audio @@ -38,8 +42,15 @@ services: - "8998:17442" image: voc0der/youtubedl-material:nightly ytdl-mongo-db: - # If you are using a Raspberry Pi, use mongo:4.4.18 - image: mongo:4 + # If you are using an older Raspberry Pi / 32-bit setup, use mongo:4.4.18 + image: mongo:8 + healthcheck: + test: ["CMD-SHELL", "mongosh --eval 'db.runCommand({ping:1}).ok' --quiet"] + interval: 15s + timeout: 30s + retries: 5 + start_period: 35s + start_interval: 1s logging: driver: "none" container_name: mongo-db diff --git a/src/app/posts.services.ts b/src/app/posts.services.ts index 358932c..051fca2 100644 --- a/src/app/posts.services.ts +++ b/src/app/posts.services.ts @@ -713,11 +713,11 @@ export class PostsService { // gets tag of the latest version of youtubedl-material getLatestGithubRelease() { - return this.http.get('https://api.github.com/repos/tzahi12345/youtubedl-material/releases/latest'); + return this.http.get('https://api.github.com/repos/voc0der/youtubedl-material/releases/latest'); } getAvailableRelease() { - return this.http.get('https://api.github.com/repos/tzahi12345/youtubedl-material/releases'); + return this.http.get('https://api.github.com/repos/voc0der/youtubedl-material/releases'); } afterLogin(user, token, permissions, available_permissions) { diff --git a/src/app/settings/settings.component.html b/src/app/settings/settings.component.html index bb0a32a..9cd0491 100644 --- a/src/app/settings/settings.component.html +++ b/src/app/settings/settings.component.html @@ -295,7 +295,7 @@ Enable RSS Feed

Be careful enabling this with multi-user mode! User data may be exposed.

-

See documentation here.

+

See documentation here.

@@ -306,14 +306,14 @@
Chrome
-

Click here to download the official YoutubeDL-Material Chrome extension manually.

+

Click here to download the official YoutubeDL-Material Chrome extension manually.

You must manually load the extension and modify the extension's settings to set the frontend URL.

Firefox

Click here to install the official YoutubeDL-Material Firefox extension right off the Firefox extensions page.

-

Detailed setup instructions. Not much is required other than changing the extension's settings to set the frontend URL.

+

Detailed setup instructions. Not much is required other than changing the extension's settings to set the frontend URL.

@@ -380,7 +380,7 @@
- + Enable notifications