Very spartan Web and REST interface for downloading youtube videos onto a server. starlette
+ yt-dlp
.
If you have python ^3.6.0 installed in your PATH you can simply run like this, providing optional environment variable overrides inline.
python -m uvicorn youtube-dl-server:app --port 8123 --host 0.0.0.0
Downloads can be triggered by supplying the {{url}}
of the requested video through the Web UI or through the REST interface via curl, etc.
Just navigate to http://{{host}}:8080/youtube-dl
and enter the requested {{url}}
.
#### Bookmarklet
Add the following bookmarklet to your bookmark bar so you can conviently send the current page url to your youtube-dl-server instance.
```javascript
javascript:!function(){window.location="http://${host}:8123/youtube-dl/q?url=" + window.location.href}();
The server uses starlette
for the web framework and youtube-dl
to handle the downloading. The integration with youtube-dl makes use of their python api.
This docker image is based on python:alpine
and consequently alpine:3.8
.