Self-hosted light-weight server proxy for YoutubeDL, originally designed for use in VRChat.
Currently in alpha.
Access the url via https://mydomain/?url=https://youtube.com/watch?v=VIDEO_ID
to receive a 307 redirect to the direct link video url.
f
: Specific format id for the given url that is desired. This is something that is looked up ahead of time via manually checking --list-formats in ytdl.s
: Custom sort order for ytdl to determine what it thinks is 'best'. Sort order options can be found Herem
: Specific presets for sort order options
0
- aka "hasvid,hasaud,res:1440" for decent sized media with audio+video, generally compatible with all platforms1
- aka "hasvid,hasaud,res" for sort preferring audio+video with the highest quality2
- aka "hasvid,hasaud,+res" for sort preferring audio+video with the lowest quality3
- aka "hasvid,res,codec:vp9" for sort preferring highest quality with priority on VP9 codec for platform compatibility4
- aka "hasvid,res" for sort preferring highest quality without concern for codec or audioIf you specified authorization tokens in your configuration, use one of the following to authorize yourself:
Authorization: Bearer <your token>
.?token=<your token>
query parameter.Use the following environment variables to configure the server.
Name | Purpose | Default |
---|---|---|
VROXY_HOST |
The host the server should bind to. | 0.0.0.0 |
PORT |
Port the server should bind to. | 8008 |
VROXY_WHITELIST |
Path to a whitelist file | No whitelist |
VROXY_AUTH_TOKENS |
comma separated list of bearer tokens. Enables authorization. | Unauthorized access allowed |
You may provide a whitelist file path via VROXY_WHITELIST
. This is a text file where each line is a domain pattern to whitelist.
You may specify:
[subdomain.]domain.tld
*.domain.tld
#
to add comments.We include an example config which attempts to match the VRChat Video Player Whitelist.
Pull the repo's install script and run it:
curl -o vroxy_install.sh https://raw.githubusercontent.com/techanon/vroxy/master/vroxy_install_deb.sh\
&& sudo bash ./vroxy_install.sh
/var/vroxy
as the install folder by default, but you can specify another location if you wish.su -
or install sudo and add yourself as a sudo user.bash /var/vroxy/vroxy_reload.sh
tmux a -t vroxy
CTRL+B
followed by the D
key.pip
tool is also installed)/var/vroxy
is recommended.python3 -m pip install -U yt-dlp aiohttp
python3 /path/to/repo/vroxy.py
In general you can deploy ghcr.io/techanon/vroxy:dev
to any platform that supports running docker containers.
On a bare VPS with Docker and docker-compose installed:
docker-compose up -d
Using make is optional if you already know how to use docker-compose.
To build the docker containers:
make
Run the tests:
make test
make test-e2e
To launch a shell inside the dev container:
make sh
To run the local development server:
docker-compose up