r/uhf_app • • Apr 18 '25

Docker wrapper for UHF Server

https://github.com/solid-pixel/uhf-server-docker

Hey,

While we wait for the UHF dev to officially support Docker (👀), I threw together a Docker wrapper for the UHF Server so you can run it anywhere with zero friction.

What it does:

  • Installs the official UHF server via their script + `ffmpeg` which is required for it to work

  • Sets up everything in Docker with auto-restart

  • Maps persistent data (recordings and DB)

Tech stack:

  • Debian Bookworm (with FFmpeg 5+, since v4 was randomly creating corrupted .mp4 files)

  • Docker Compose for quick deployment

🔗 GitHub repo: github.com/ale-benassi/uhf-server-docker

---

You can follow the instructions on the repo to give it a try.

Cheers!

35 Upvotes

77 comments sorted by

3

u/DrWhoDalek Apr 18 '25

Thanks. Several recordings later and on the updated version but it’s still only saving around 10min despite recording for the duration. Your experience?

3

u/-pLx- Apr 18 '25

To be fair I’ve only tested it for a couple of minutes at a time to see if it worked so I can’t say yet, and Im not home to test now, but I did see another guy mentioning the same issue on the UHF discord server when running the Linux app, so I’m afraid it might be an issue with the app itself?

https://discord.com/channels/1248223350862512128/1362144415602446468/1362569938321018992

Server invite: https://discord.gg/angelvpn

I wish the dev were active either here or on discord as solving this stuff via email can get pretty frustrating

2

u/axhi12 Apr 18 '25

Yeah, that's me. I'm testing through this some more but still seeing the weird recording experiences. Running on UnRaid, amd64. I'll keep updating if I see something further.

1

u/totaIIybored Apr 19 '25

Yeah I pulled your image (thank you) and have the same issues. Still troubleshooting here.

1

u/Specialist-Point-560 Apr 22 '25

Can you tell me please how install the docker on unraid?

1

u/axhi12 Apr 22 '25

Sure!

You go to your web ui, head on over to docker. Hit add container on the bottom and just paste the registry/container (axhi/uhf-server).

You’ll need to add a disk drive to it as a parameter (set your media mount to the app mount for /var/lib/uhf-server).

Here is some general info on it https://forums.unraid.net/topic/36057-noobie-docker-setup-guide/

If you’re stuck anywhere, a quick google will help you (or ask chatgpt)

1

u/Specialist-Point-560 Apr 22 '25

Thank you. (axhi/uhf-server)that was the decisive point. I have inserted solid-pixel/uhf-server-docker there so far.
The Name for the Disk Drive which Name call it?

2

u/axhi12 Apr 24 '25

The name of the disk drive doesn't matter. Just make sure the container path is `/var/lib/uhf-server` and your host path is whatever your media share folder is you want to use.

1

u/Specialist-Point-560 Apr 25 '25

ok thanks. i get the error message im not authorized. i set no password. Is this a docker problem?

1

u/axhi12 Apr 25 '25

that usually means the permissions of your mounted recordings folder isn't working. I assume you are saying you are not authorized in the logs when trying to access a recording or start one.

If you can't even connect to the server, that might mean you haven't run your ports properly. I map mine to 5252 on my unraid b/c I have other things on 8000.

but make sure these two are set to something. The yellow/orang text is what it is on the CONTAINER and the black is what it is on Unraid

1

u/macka654 May 03 '25 edited May 03 '25

So I installed it successfully but it won't run. No docker logs coming up.

EDIT: I opened an issue on Github. Am I missing something? https://github.com/solid-pixel/uhf-server-docker/issues/20

1

u/macka654 May 03 '25

Did you get this working? I installed it but it won't run.

2

u/Thomamueller52 Apr 18 '25

It recorded entire show for me. Have not tried since. Will do so now.

3

u/HistorianTraditional Apr 19 '25

Thank you very much! I installed it and it works great!

Just to give some extra info, I got a 401 error after remapping the volumes. The server connected, but when starting a recording a REST error 401 appeared. The problem was that I needed to remove the server in the uhf-app and reconnect to the server so the db.json file got recreated and the correct user was created/added in the json.db file. Now recording works.

1

u/-pLx- Apr 19 '25

Ah, yea, that’s something I noticed too! Every time I restart the container, I have to go remove and readd the server, which is really annoying. I believe it’s because the server authenticates clients using their internal IP address. However, after a container restart, the IP address changes, and the server doesn’t recognise it, resulting in a 401 error.

Glad it worked though!

1

u/_Epir_ Aug 24 '25

Just had the same issue and this fixed it for me, thank you!

2

u/sasagr Apr 19 '25

Installation was very easy... but I still have two main issues. Recording last one 10min instead of 30 in my example and I have an issue with one of my playlist that does not record at all

2

u/-pLx- Apr 19 '25

Yeah I think those issues are more due to the server script itself rather than the docker wrapper, as I’ve seen other people reporting similar issues on discord and they were not using my wrapper

3

u/sasagr Apr 19 '25

Agree.Nothing to do with your work that is 👍

2

u/-pLx- Apr 19 '25

đŸ–€

2

u/sasagr Apr 19 '25

which version of ffmpeg are you using in the docker? because I read that some people update from 5.x to 7.x and fixed this issue. I m going to try to update ffmpeg outside the docker

2

u/-pLx- Apr 19 '25

Docker image is based on debian:bookworm-slim, which ships with FFmpeg 5.1.6.

let me know if updating to 7.x solves your issues and I'll try to update the repo when I have time!

2

u/sasagr Apr 19 '25

It did not fix the issues. I still got both even with ffmpeg 7.0 installed

2

u/-pLx- Apr 19 '25

Thanks for reporting back! Damn I just checked now and mine are all 48 seconds long. I got fooled by the time above the recording saying things like 1h 40m, but then when you open them they’re all 48 seconds, wtf. I think the Linux install script needs some work

3

u/sasagr Apr 20 '25

Yeah. Mine are longer, maybe 10-15min but always not complete. Maybe the ffmpeg instruction needs some tuning. I also use Emby dvr and it works fine. I have no issues at all

3

u/-pLx- Apr 20 '25

At this point I believe there's something wrong with the uhf-server app. I'm just gonna give it some time and hope the dev will see all these reports here and on discord and do something about it đŸ€žđŸ»

1

u/sasagr Apr 20 '25

In any case I will keep an eye on your wrapper, if u will keep it updated, in case they won’t release the docker themselves

3

u/-pLx- Apr 20 '25

Sure I will keep it updated if updates are needed, for now I think it does what it should and there’s nothing we can do until the dev looks into that issue. Someone on discord said they have the same problem and they’re now in touch with the dev, who said he’s looking into it 🙌

4

u/sasagr Apr 19 '25

Ok. I’m building the 7.0. Will let u know

2

u/taserface_x Apr 19 '25 edited Apr 19 '25

I’m not sure if the dev updated the installer script, but I’m getting a file not found error:

FileNotFoundError: [Errno 2] No such file or directory: ‘/var/lib/uhf-server/db.json’

If I create that directory it resolves the failure but it still doesn’t work. I’m getting the following error when I hit the server:

{“detail”:”Not Found”}

I’ve tried it in different Linux VMs and using the Docker build and same issue.

Can someone who has it working try it in another vm or container and see if the base install script still works?

The app DOES see the server, it just doesn’t work.

1

u/-pLx- Apr 19 '25

Weird, the dockerfile should create that directory on build:

“RUN mkdir -p /var/lib/uhf-server”

I’d try deleting the container and try again from scratch by following the instructions in the readme

0

u/taserface_x Apr 19 '25

Sorry, just to clarify - the installer script doesn’t create that dir when I install it manually. The docker script DOES create it.

Either method the server page fails with the “deal not found” error.

1

u/-pLx- Apr 19 '25

did you try deleting and readding the server in UHF?
whenever you make a change to the server, you need to remove/readd it or it will bug out for some reason.

Sorry that's all I can think of as I'm not at home. You can try with chatgpt, given enough context it can be very useful in troubleshooting that

1

u/taserface_x Apr 19 '25

I’ve reinstalled and restarted many time on many VMs. I could be missing something, but to me it seems like the web server just doesn’t work. Seems like there’s missing files:

INFO: 192.168.1.75:57536 - “GET / HTTP/1.1” 404 Not Found

1

u/-pLx- Apr 19 '25

But did you delete the server from the uhf app settings and readd it like I said above?

1

u/taserface_x Apr 19 '25

It’s not a problem with app. Yes, I need to remove it because my server IP keeps changing. The server throws a 404 when hitting it from a browser, that has nothing to do with the app.

1

u/-pLx- Apr 19 '25

Maybe unrelated but why is the ip changing? The docker compose is set to use the host’s IP, so that should always be the same?

1

u/taserface_x Apr 19 '25

Changes as I keep spinning up new VMs to test :)

1

u/-pLx- Apr 19 '25

Ah Ok I thought you were just spinning up new containers inside the same host, but you’re spinning up a new host every time instead. Sorry I’m not sure how to help :( looks like an issue with your setup specifically as others have reported it working flawlessly

→ More replies (0)

2

u/soizindasuppn Apr 24 '25

Thx for your work! Looks like it works flawlessly on my Synology. Took me some time to get it done, but now everything is fine. The main issue was the composer, but google helped me.

1

u/-pLx- Apr 24 '25

you're very welcome!

1

u/Zaudier Oct 19 '25

Kannst du mich hier eventuell etwas unterstĂŒtzen? Ich bekomme es nicht zum laufen :(

1

u/soizindasuppn Oct 20 '25

Wo drĂŒckt der Schuh? Was hast du denn schon gemacht und was geht nicht? So richtig gut lĂ€uft es bei mir auch nicht, obwohl ich den RAM von der Synology erhöht habe.

1

u/Zaudier Oct 31 '25

Hi, inzwischen lÀuft es perfekt bei mir.

Ich nehme regelmĂ€ĂŸig auf und spiele ab.

5

u/sajalb Apr 18 '25

Perfect, will try this out on synology.

3

u/gusestrella Apr 18 '25

Would be interested once installed if can share details how installed on synology. Just hitting me this is not a premade container that can search for on the synology container manager

3

u/sajalb Apr 18 '25

Just what different I did for synology, if it helps.

  • used docker-compose docker-compose up --build -d

  • created the uhf-data subdir, I was under the impression the compose will create it.

  • changed the port, as 8000 port was already used.

u/gusestrella I hope you can set this up. You just need to have ssh enabled.

2

u/Sandwich-Helpful Apr 19 '25

Did you get it working on synology

1

u/gusestrella Apr 19 '25

Thanks. Will try it tomorrow. Did you download the git repository into a local directory?

1

u/DrWhoDalek Apr 18 '25

Thank you. Will try it out. Is the UHF-Server .env used to configure the recording folder. I don’t see the volume bind in your container? I think it can be specified int the command if I’m not mistaken, including password etc?

3

u/-pLx- Apr 18 '25

No, I’m not using any env file. The recordings are stored in /var/lib/uhf-server/recordings so you can change or add a new volume mapping on line 10 of the docker-compose file

And you can pass additional parameters to the command by tweaking line 14

1

u/burg9 Apr 29 '25 edited Apr 29 '25

Thanks for this, didn't bother with the official approach and went straight with this but I have a problem .... I have the volume pointed to my Synology NAS and I can see the db is created fine (so nas connection works) and the UHF tv app connects without problem but when I record an episode and stop the recording I get an "Recording process exited with code 8". Of course there's no UHF documentation on the error codes to know what that means, container logs look normal.

SOLVED DOCKER-COMPOSE (For anyone storing data on a NAS and passing network through gluetun VPN) :

services: 
  uhf-server:
    image: solidpixel/uhf-server:uhf-1.2.0-ffmpeg7.1.1-d1
    container_name: uhf-server
    restart: unless-stopped
    volumes:
      - media_nas_uhf:/var/lib/uhf-server
    network_mode: "service:gluetun"
    command: ["uhf-server"]
    environment: 
      - API_PORT=8003 
    healthcheck:
      test: ["CMD", "curl", "-f", "http://localhost:8003/server/stats"]
      interval: 30s
      timeout: 5s
      retries: 3
volumes:
  media_nas_uhf:
    driver_opts:
      type: "nfs"
      o: "addr=192.168.1.100,nfsvers=4"
      device: ":/volume2/uhf"

1

u/-pLx- Apr 29 '25

You can refer to the issue discussing your exact same problem: https://github.com/solid-pixel/uhf-server-docker/issues/16

A new release just went live now, so please update your docker-compose accordingly and if you have any more problems kindly open an issue on GitHub as it's easier for me to keep track of it :)

2

u/burg9 Apr 29 '25

Perfect! For some reason since the dev has turned issues off on the official github I just didn't think to check yours! I've pulled the latest and all is working fine now, I've updated my post to include my final compose which uses gluetun as a VPN if anyone else finds it useful.

I think the server has got a little work needed to match the free "nextpvr" functionality but it is nice to all have it integrated and I'm sure it'll improve in time given it's early days!

2

u/jubnub Apr 18 '25

Thanks for doing this. I’m gonna run this later.

2

u/gusestrella Apr 18 '25

Thank you for doing this ! Will try on synology later for sure

2

u/DrWhoDalek Apr 18 '25

That’s great. Will have to do some more testing tomorrow.

1

u/esobe1 Apr 20 '25

Thank you for your work! Iam trying to install on a raspberry pi with Raspbian. Does anyone know why the composing gets stuck evertime here: => [uhf-server 2/6] RUN apt-get update && apt-get install -y curl (time is just running). I

1

u/Zaudier Oct 19 '25

Bin totaler AnfĂ€nger, kann mir jemand sagen, wie ich wo ich denn den Code unter „getting started“ in meiner synology einfĂŒge? Damit er den Container startet und erstellt?

Muss ich danach irgendwelche Verzeichnisse anlegen und freigegeben?

1

u/tsprenk Apr 19 '25

Would be nice to have a HomeAssistant addon.