Web app¶
Running Rewyt with containers is the recommended way to get started.
Note
This guide uses Podman, but Docker works too. Commands are mostly the
same with docker in place of podman, though some steps (like
podman machine and podman artifact) don’t have a direct Docker
equivalent.
The app runs as two containers managed by Compose:
- Rewyt (ghcr.io/xymaxim/rewyt): the main app, with yt-dlp, ffmpeg, and ypb inside
- PO token provider (brainicism/bgutil-ytdlp-pot-provider): handles YouTube’s bot verification in the background
Prerequisites¶
macOS and Windows¶
On macOS and Windows, Podman requires a virtual machine. Initialize and start it once:
The machine starts automatically on subsequent reboots.
Set up¶
- Pull the compose file and extract it to a local directory:
podman artifact pull ghcr.io/xymaxim/rewyt-compose
podman artifact extract ghcr.io/xymaxim/rewyt-compose ~/rewyt-app
cd ~/rewyt-app
This gives you compose.yaml and .env.template files with defaults,
containing configuration variables, including ypb’s — see
Configuration below for what’s available.
- Copy
.env.templateto.env:
.env is yours to customize and won’t be overwritten by future updates.
Set up cookies (recommended)¶
YouTube may respond with a “Sign in to confirm you’re not a bot” error without cookies, so setting them up is recommended. To avoid this:
- Export cookies from your browser into a
cookies.txtfile. - In
.env(see Set up above), setYPB_YTDLP_CONFIG_DIRto the directory where you want to store yt-dlp related config files. - Place
cookies.txtinside that directory. - Reference it from your yt-dlp config file:
--cookies /path/to/cookies.txt
Usage¶
Start the app:
Then open it in your browser:
http://localhost:8080
When done, shut down the app and the PO token provider sidecar:
Configuration¶
The .env.template file (copied to .env during setup) holds
configuration variables, including ypb’s. See ypb’s
Configuration
section for what’s available and how to set them.
Update the app¶
To update the container images:
To pick up changes to compose.yaml or .env.template, re-run the extract
step. This leaves your .env untouched: