2018-02-10 23:37:42 +00:00
2020-01-22 00:59:16 +00:00
<!DOCTYPE html>
2017-09-20 02:35:05 +00:00
2021-04-10 04:00:37 +00:00
< html >
2017-09-20 02:35:05 +00:00
< head >
2020-01-22 00:59:16 +00:00
< meta charset = "utf-8" / >
2021-06-22 00:16:40 +00:00
< meta name = "viewport" content = "width=device-width, initial-scale=1.0" / > < meta name = "generator" content = "Docutils 0.17.1: http://docutils.sourceforge.net/" / >
2017-09-20 02:35:05 +00:00
< title > Using Docker — Shaka Packager documentation< / title >
2021-06-22 00:16:40 +00:00
< link rel = "stylesheet" type = "text/css" href = "_static/pygments.css" / >
< link rel = "stylesheet" type = "text/css" href = "_static/sphinxdoc_new.css" / >
2020-01-22 00:59:16 +00:00
< link rel = "stylesheet" type = "text/css" href = "_static/graphviz.css" / >
< link rel = "stylesheet" type = "text/css" href = "_static/table_styling.css" / >
2021-06-22 00:16:40 +00:00
< script data-url_root = "./" id = "documentation_options" src = "_static/documentation_options.js" > < / script >
2021-04-10 04:00:37 +00:00
< script src = "_static/jquery.js" > < / script >
< script src = "_static/underscore.js" > < / script >
< script src = "_static/doctools.js" > < / script >
2017-09-20 02:35:05 +00:00
< link rel = "index" title = "Index" href = "genindex.html" / >
< link rel = "search" title = "Search" href = "search.html" / >
< link rel = "next" title = "Shaka Packager Library (Continued)" href = "library_details.html" / >
< link rel = "prev" title = "Build Instructions" href = "build_instructions.html" / >
2020-01-22 00:59:16 +00:00
< / head > < body >
2017-09-20 02:35:05 +00:00
< div class = "related" role = "navigation" aria-label = "related navigation" >
< h3 > Navigation< / h3 >
< ul >
< li class = "right" style = "margin-right: 10px" >
< a href = "genindex.html" title = "General Index"
accesskey="I">index< / a > < / li >
< li class = "right" >
< a href = "library_details.html" title = "Shaka Packager Library (Continued)"
accesskey="N">next< / a > |< / li >
< li class = "right" >
< a href = "build_instructions.html" title = "Build Instructions"
accesskey="P">previous< / a > |< / li >
2021-04-10 04:00:37 +00:00
< li class = "nav-item nav-item-0" > < a href = "index.html" > Shaka Packager documentation< / a > » < / li >
< li class = "nav-item nav-item-this" > < a href = "" > Using Docker< / a > < / li >
2017-09-20 02:35:05 +00:00
< / ul >
2021-04-10 04:00:37 +00:00
< / div >
2017-09-20 02:35:05 +00:00
< div class = "document" >
< div class = "documentwrapper" >
< div class = "bodywrapper" >
< div class = "body" role = "main" >
2021-06-22 00:16:40 +00:00
< section id = "using-docker" >
2020-01-22 00:59:16 +00:00
< h1 > Using Docker< a class = "headerlink" href = "#using-docker" title = "Permalink to this headline" > ¶< / a > < / h1 >
2017-09-20 02:35:05 +00:00
< p > < a class = "reference external" href = "https://www.docker.com/whatisdocker" > Docker< / a > is a tool that can package an
application and its dependencies in a virtual container to run on different
host operating systems.< / p >
2021-06-22 00:16:40 +00:00
< section id = "get-shaka-packager-from-dockerhub" >
2020-01-22 00:59:16 +00:00
< h2 > Get Shaka Packager from Dockerhub< a class = "headerlink" href = "#get-shaka-packager-from-dockerhub" title = "Permalink to this headline" > ¶< / a > < / h2 >
2017-09-20 02:35:05 +00:00
< p > To pull latest Shaka Packager:< / p >
2020-01-22 00:59:16 +00:00
< div class = "highlight-shell notranslate" > < div class = "highlight" > < pre > < span > < / span > $ docker pull google/shaka-packager
2017-09-20 02:35:05 +00:00
< / pre > < / div >
< / div >
< p > You can pull a specific version, e.g. v1.6.2:< / p >
2020-01-22 00:59:16 +00:00
< div class = "highlight-shell notranslate" > < div class = "highlight" > < pre > < span > < / span > $ docker pull google/shaka-packager:release-v1.6.2
2017-09-20 02:35:05 +00:00
< / pre > < / div >
< / div >
< p > The full list of tags is available
< a class = "reference external" href = "https://hub.docker.com/r/google/shaka-packager/tags/" > here< / a > .< / p >
2021-06-22 00:16:40 +00:00
< / section >
< section id = "run-the-container" >
2020-01-22 00:59:16 +00:00
< h2 > Run the container< a class = "headerlink" href = "#run-the-container" title = "Permalink to this headline" > ¶< / a > < / h2 >
< p > Assume you have your media files stored in < code class = "docutils literal notranslate" > < span class = "pre" > host_media_path< / span > < / code > in the host
2017-09-20 02:35:05 +00:00
machine.< / p >
2020-01-22 00:59:16 +00:00
< p > This runs the container and maps < code class = "docutils literal notranslate" > < span class = "pre" > host_media_path< / span > < / code > to < code class = "docutils literal notranslate" > < span class = "pre" > media< / span > < / code > in the container:< / p >
< div class = "highlight-shell notranslate" > < div class = "highlight" > < pre > < span > < / span > $ docker run -v /host_media_path/:/media -it --rm google/shaka-packager
2017-09-20 02:35:05 +00:00
< / pre > < / div >
< / div >
2017-12-12 02:14:43 +00:00
< p > Note that the networking in the container is containerized by default, so if
you want to access UDP multicast in the host network, you will need to configure
2020-01-22 00:59:16 +00:00
the network explicitly. You may do this with < code class = "docutils literal notranslate" > < span class = "pre" > --net=host< / span > < / code > option, i.e.< / p >
< div class = "highlight-shell notranslate" > < div class = "highlight" > < pre > < span > < / span > $ docker run -v /host_media_path/:/media -it --net< span class = "o" > =< / span > host --rm google/shaka-packager
2017-12-12 02:14:43 +00:00
< / pre > < / div >
< / div >
2017-09-20 02:35:05 +00:00
< p > Then in the container, run the packager command, e.g.:< / p >
2020-01-22 00:59:16 +00:00
< div class = "highlight-shell notranslate" > < div class = "highlight" > < pre > < span > < / span > $ packager < span class = "nv" > input< / span > < span class = "o" > =< / span > /media/example.mp4,stream< span class = "o" > =< / span > audio,output< span class = "o" > =< / span > /media/audio.mp4 < span class = "se" > \< / span >
2017-09-20 02:35:05 +00:00
< span class = "nv" > input< / span > < span class = "o" > =< / span > /media/example.mp4,stream< span class = "o" > =< / span > video,output< span class = "o" > =< / span > /media/video.mp4 < span class = "se" > \< / span >
--mpd_output /media/example.mpd
< / pre > < / div >
< / div >
2020-01-22 00:59:16 +00:00
< p > Outputs are available in the host’ s media folder < code class = "docutils literal notranslate" > < span class = "pre" > host_media_path< / span > < / code > .< / p >
2021-06-22 00:16:40 +00:00
< / section >
< / section >
2017-09-20 02:35:05 +00:00
2021-04-10 04:00:37 +00:00
< div class = "clearer" > < / div >
2017-09-20 02:35:05 +00:00
< / div >
< / div >
< / div >
2021-04-10 04:00:37 +00:00
< div class = "sphinxsidebar" role = "navigation" aria-label = "main navigation" >
< div class = "sphinxsidebarwrapper" >
< h3 > < a href = "index.html" > Table of Contents< / a > < / h3 >
< ul >
< li > < a class = "reference internal" href = "#" > Using Docker< / a > < ul >
< li > < a class = "reference internal" href = "#get-shaka-packager-from-dockerhub" > Get Shaka Packager from Dockerhub< / a > < / li >
< li > < a class = "reference internal" href = "#run-the-container" > Run the container< / a > < / li >
< / ul >
< / li >
< / ul >
< h4 > Previous topic< / h4 >
< p class = "topless" > < a href = "build_instructions.html"
title="previous chapter">Build Instructions< / a > < / p >
< h4 > Next topic< / h4 >
< p class = "topless" > < a href = "library_details.html"
title="next chapter">Shaka Packager Library (Continued)< / a > < / p >
< div role = "note" aria-label = "source link" >
< h3 > This Page< / h3 >
< ul class = "this-page-menu" >
< li > < a href = "_sources/docker_instructions.md.txt"
rel="nofollow">Show Source< / a > < / li >
< / ul >
< / div >
< div id = "searchbox" style = "display: none" role = "search" >
< h3 id = "searchlabel" > Quick search< / h3 >
< div class = "searchformwrapper" >
< form class = "search" action = "search.html" method = "get" >
< input type = "text" name = "q" aria-labelledby = "searchlabel" / >
< input type = "submit" value = "Go" / >
< / form >
< / div >
< / div >
< script > $ ( '#searchbox' ) . show ( 0 ) ; < / script >
< / div >
< / div >
2017-09-20 02:35:05 +00:00
< div class = "clearer" > < / div >
< / div >
< div class = "related" role = "navigation" aria-label = "related navigation" >
< h3 > Navigation< / h3 >
< ul >
< li class = "right" style = "margin-right: 10px" >
< a href = "genindex.html" title = "General Index"
>index< / a > < / li >
< li class = "right" >
< a href = "library_details.html" title = "Shaka Packager Library (Continued)"
>next< / a > |< / li >
< li class = "right" >
< a href = "build_instructions.html" title = "Build Instructions"
>previous< / a > |< / li >
2021-04-10 04:00:37 +00:00
< li class = "nav-item nav-item-0" > < a href = "index.html" > Shaka Packager documentation< / a > » < / li >
< li class = "nav-item nav-item-this" > < a href = "" > Using Docker< / a > < / li >
2017-09-20 02:35:05 +00:00
< / ul >
< / div >
< div class = "footer" role = "contentinfo" >
© Copyright 2017, Google.
2021-06-22 00:16:40 +00:00
Created using < a href = "https://www.sphinx-doc.org/" > Sphinx< / a > 4.0.2.
2017-09-20 02:35:05 +00:00
< / div >
< / body >
< / html >