I had a heckuva time getting HW transcoding working within docker. However, I’m now operational: http://i.imgur.com/jB33Phr.png I’m going to mention this a few times, I have to verify all of the below steps, primarily the adding of video drivers within the container itself. For the record I have an Ubuntu 16.04 LTS server with an i7-4790K processor in it, this means all of this can and will possibly be very different for you.

Install the latest docker: https://forums.plex.tv/discussion/comment/1334624/#Comment_1334624 be certain to follow the additional instructions included here. Primarily the downloading of the proper image, and running the install >> Just don’t restart the container.

What you’ll notice upon following that post is, it will never come up on 1.4.x , that’s because on boot docker will continuously grab the latest plex pass version because the text in /version.txt will force it to effectively roll back. Correct this by doing the following:

( credit to this post: https://forums.plex.tv/discussion/comment/1347801/#Comment_1347801 )

Outlined here:

From the host OS to get into the container: docker exec -it plex /bin/bash

From the container OS: echo 1.4.0.3173-04b80c8>/version.txt

Now restart the container, and it should come up on the proper version.

Go in and check the box to enable HW transcoding: http://i.imgur.com/j0nzRX5.png

What you’ll now see is that HW transcoding won’t seem to work. I did some research around the web…

I got ahead of myself, (started dartboard troubleshooting and i hate that) and need to do additional testing, however I think the following will do the job: (Again all these steps need confirmation)

(The following steps also assume you are running docker as uid plex gid plex 1000)

On the host OS: chown -R plex:plex /dev/dri *this will go away on restart/reboot, this has to be addressed.

On the container: chown -R plex:plex /dev/dri *this will go away on restart/reboot, this has to be addressed.

The following portion is ONLY done on the container. None of this is the part where I need to circle back and verify things.

Again get into the container: docker exec -it plex /bin/bash

apt-get update

apt-get install vainfo

I did that, and I think that may have actually covered what I needed, I’m going to build a test docker install to verify all of this, but I ended up doing these as well before I did a proper test:

apt-get install libgles1-mesa,

apt-get install libgles2-mesa

apt-get install libegl1-mesa-drivers

apt-get install libgl1-mesa-dri

apt-get install mesa-vdpau-drivers

apt-get install intel-vaapi-driver (*this actually didn’t work but I believe was covered in the base install of the OS or via dependencies covered within the install of vainfo)

From here verify what you see, run the command: vainfo . Here’s what I now get:



As stated, I’m almost certain I went to far with what I installed in the container. However, it is now fully operational and i’m seeing great results from a CPU usage perspective when transcoding content.

I would certainly enjoy developer commentary from plex if possible. I’m going to re-create this docker at some point and minimize the steps, as I’m not sure if all of those drivers need to actually be installed.