Skip to content

Bug: I can't seem to specify YOUTUBEDL_ARGS or YTDLP_EXTRA_ARGS #1613

Closed
ArchiveBox/abx-plugins
#97

Description

@melyux

I'm trying to run an archivebox add command with specific yt-dlp flags, on the latest development commit.

But I'm trying every escaping variation of docker compose exec --user=archivebox archivebox /bin/bash -c "env YTDLP_EXTRA_ARGS=[\"--limit-rate=10M\"] archivebox config --get YTDLP_EXTRA_ARGS" and it doesn't seem to work, and same with YOUTUBEDL_ARGS (did it change?).

I used to be able to do: docker compose run --rm archivebox "config --get URL_BLACKLIST && YOUTUBEDL_ARGS='[\"--restrict-filenames\"]' /usr/local/bin/archivebox add 'https://www.youtube.com/shorts/blahblahblah'" and it would just work. The && was to be able to enter the environment variable before the archivebox command, but now that's not allowed.

Activity

  1. pirate commented on Dec 9, 2024

    @pirate
    Member

    You can pass env vars with -e https://docs.docker.com/compose/how-tos/environment-variables/set-environment-variables/#set-environment-variables-with-docker-compose-run---env

    You can also do docker compose run --rm archivebox /bin/bash -c '...' if you want to run arbitrary shell stuff inside the docker container.

  2. melyux commented on Dec 10, 2024

    @melyux
    Author

    Thanks for that. But even though this works perfectly like this:

    docker compose run --rm archivebox config --set YTDLP_EXTRA_ARGS='["--write-description", "--write-info-json", "--write-annotations", "--write-thumbnail", "--no-call-home", "--write-sub", "--all-subs", "--write-auto-sub", "--convert-subs=srt", "--yes-playlist", "--continue", "--ignore-errors", "--geo-bypass", "--add-metadata", "--max-filesize=500m", "--sub-lang=en"]'

    ...running this with the -e flag doesn't seem to affect the config (even though it works with other config options):

    docker compose run --rm -e YTDLP_EXTRA_ARGS='["--write-description", "--write-info-json", "--write-annotations", "--write-thumbnail", "--no-call-home", "--write-sub", "--all-subs", "--write-auto-sub", "--convert-subs=srt", "--yes-playlist", "--continue", "--ignore-errors", "--geo-bypass", "--add-metadata", "--max-filesize=500m", "--sub-lang=en"]' archivebox config --get YTDLP_EXTRA_ARGS

    It just prints the default arguments instead of the ones I put in the -e flag.

    The second option with docker compose run --rm archivebox /bin/bash -c "YTDLP_EXTRA_ARGS='[\"--write-comments\"]' archivebox config --get YTDLP_EXTRA_ARGS" also doesn't work, it just prints out the default YTDLP_EXTRA_ARGS config

  3. Eugeo-Agent commented on Oct 10, 2026

    @Eugeo-Agent

    The legacy YOUTUBEDL_ARGS name was dropped when ytdlp config moved to the plugin schema (it now only accepts YTDLP_ARGS_EXTRA / alias YTDLP_EXTRA_ARGS). PR ArchiveBox/abx-plugins#97 re-adds YOUTUBEDL_ARGS as an alias so all three names resolve to the same key.

    Verified end-to-end: YOUTUBEDL_ARGS='["--restrict-filenames"]' archivebox config --get YOUTUBEDL_ARGS now returns YTDLP_ARGS_EXTRA = [ "--restrict-filenames",].

    🤖 Commented by Eugeo, an AI agent steered by @hallo-there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions