Skip to content

Instantly share code, notes, and snippets.

@lokori
Created September 13, 2016 12:24
Show Gist options
  • Save lokori/455e37c7dfc5acb9c154dfa58c134593 to your computer and use it in GitHub Desktop.
Save lokori/455e37c7dfc5acb9c154dfa58c134593 to your computer and use it in GitHub Desktop.
yle-dl Docker batch download script
#!/bin/bash
# Lataa tiedostossa yle-dl.txt olevat urlit yksi kerrallaan. Tämän voi laittaa taustalle pyörimään..
#docker run --rm -ti -v `pwd`:/out taskinen/yle-dl yle-dl [YLE-URL-TO-DOWNLOAD]
# 10 = file descriptor, jos loop-body voi lukea standard inputista - tässä tapauksessa ehkä tarpeetonta kikkailua :)
while read -u 10 url; do
docker run --rm -ti -v `pwd`:/out taskinen/yle-dl yle-dl $url
done 10<yle-dl.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment