There are many docker images to remove commercials. The one I’ve tried is:
uirel/lsio-plex-comskip
I find indeed it does remove most of the commercials from shows. However, every encoding also shows up as an error:
An error occurred while postprocessing the recording
Making it impossible to know if the show really succeeded without watching it.
It seems practically all the docker images are forked from the same source, and they use the same comskip.sh script. One error I noticed is they call mkvpropedit even when the input is a *.ts file. I’ve revised the script as follows:
The exit 0 makes it always successful. The piping the error to /dev/null speeds the script up, as sometimes there is excessive amount of debugging output. The nice keeps it from interfering with the transcoder. The TMPDIR setting keeps it from failing because it fills up /tmp. I also noticed this process is fairly slow. It takes about 22 minutes to process a 30 minute show on my server. Which means if the transcoder is running as well, back to back recordings will attempt to process in parallel. So I end-up turning off the transcoding of DVR files. Turns out to get decent compression, I need to run handbrake over the files, so there is little use in transcoding as the files are recording.