goofball222/unifi

RUN_CHOWN failure should not necessarily be fatal

jhughes2112 opened this issue · 1 comments

Hi! Much love, this project has been great.

I am running v6.2.26 now and it seems to work well, inside Kubernetes. I figured out how to get cert-manager to use Let's Encrypt to generate a certificate for me, store it in a Secret, then map the two files into the container pod. That was tricky, because I run as uid/gid 999:999 instead of root. When volumes are mapped into the space, they do so as root. It took a while to get those settings right, but once I did, I kept failing repeatedly at RUN_CHOWN, because it cannot modify the read-only mapping of those certificate files.

To get it to run past that point, I had to set RUN_CHOWN = false. Otherwise seems to work fine. It might be good to ignore errors on that particular line, because really, if it fails later, it won't be because chown failed. It'll be because of some other reason.

Thanks!

Setting the environment variable RUN_CHOWN = false is the proper approach to this. Configuring it is saying "yes, I've confirmed that the permissions to everything on volumes attached to the container are correct". It's defaulted to true to insure ease of use for deployments where someone might not be familiar with filesystem permissions/ACLs.