From 0cab314d8347ef97ab74d43642806ba55f745012 Mon Sep 17 00:00:00 2001 From: ccErrors Date: Mon, 26 Jun 2023 10:24:25 +0200 Subject: [PATCH 1/2] fix #92 --- .../1.tv-and-media/content-from-youtube.md | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md diff --git a/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md b/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md new file mode 100644 index 00000000..6e833f6a --- /dev/null +++ b/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md @@ -0,0 +1,39 @@ +--- +title: "Content from Youtube" +date: 2023-02-23 +--- +Sometimes you need to add content from Youtube to Astra. +This note shows how to do this using the youtube-dl utility. + +### Install youtube-dl and ffmpeg + +youtube-dl is a small program for capturing video content from youtube + +##### Centos 8: + +```sh +dnf install epel-release dnf-utils +yum-config-manager --set-enabled PowerTools +yum-config-manager --add-repo=https://negativo17.org/repos/epel-multimedia.repo +yum install youtube-dl ffmpeg +``` + +##### Ubuntu 18.04: + +```sh +sudo apt-get install youtube-dl ffmpeg +``` + +### Example + +`https://www.youtube.com/watch?v=9Auq9mYxFEE"` - address of the page with the content. +`udp://lo@127.0.0.1:5613` - multicast address from which Astra will pick up the ready udp stream. + +Run in the console: + +```sh +youtube-dl "https://www.youtube.com/watch?v=9Auq9mYxFEE" -o - | ffmpeg -i pipe:0 -vcodec h264 -acodec copy -muxrate 4000000 -f mpegts "udp://lo@127.0.0.1:5613/?pkt_size=1316" +``` + +create a stream in the Astra web interface with the source `udp://lo@127.0.0.1:5613` +Done! From 53a05cfafaa4d1fb9ea3b2d38a6688683b9de612 Mon Sep 17 00:00:00 2001 From: ccErrors Date: Tue, 27 Jun 2023 18:48:44 +0200 Subject: [PATCH 2/2] fix headers --- .../1.tv-and-media/content-from-youtube.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md b/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md index 6e833f6a..500e3448 100644 --- a/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md +++ b/content/3.misc/1.tools-and-utilities/1.tv-and-media/content-from-youtube.md @@ -5,11 +5,11 @@ date: 2023-02-23 Sometimes you need to add content from Youtube to Astra. This note shows how to do this using the youtube-dl utility. -### Install youtube-dl and ffmpeg +## Install youtube-dl and ffmpeg youtube-dl is a small program for capturing video content from youtube -##### Centos 8: +### Centos 8: ```sh dnf install epel-release dnf-utils @@ -18,7 +18,7 @@ yum-config-manager --add-repo=https://negativo17.org/repos/epel-multimedia.repo yum install youtube-dl ffmpeg ``` -##### Ubuntu 18.04: +### Ubuntu 18.04: ```sh sudo apt-get install youtube-dl ffmpeg