Had a bear of a time with this, and got it to work. Intel Xeon 1225v6
FreeNAS 11.3-U1: /dev/dri did not show up on FreeNAS itself. Edit: I did this to myself. I had a compat.linuxkpi.modeset tunable with value 0, and while it had been disabled, that value "hung around". Setting it to "-1" had /dev/dri show up, and now hw transcode works in Plex 1.18.8 on 11.3U1, as well.
FreeNAS 12.0-nightly-0312: /dev/dri does show up on FreeNAS itself. Note this breaks IPMI KVM, and I haven't found a way around that. A LOADER tunable with compat.linuxkpi.i915_modeset and value 0 will keep IPMI as output, but then /dev/dri isn't present.
Nightly is profoundly unstable of course. I went there out of curiosity, since 11.3 didn't load the drivers for my iGPU - turns out I needed a better modeset tunable, not 12.0. Learn something every day.
/dev/dri would show up in the jail, but Plex 1.18.3 didn't use hw transcode.
I upgraded plex to 1.18.8 and now hw transcode works.
I may need to go and install plex in a regular jail, not a plugin, if I want to keep using hw transcode, so the intel media pkg doesn't disappear itself on update.
I played around with kld_list tunable. That probably would work, but for now I am doing what
@toyebox suggests: service devfs restart and kldload after that, in the script.
Where previously Plex took 100% CPU to transcode a 4k video, now it takes 4% or thereabouts. Quality seems to be okay, though HDR to SDR transcoding is never going to be great. I'll still opt to store a 1080p native file where I have one.