Skip to content
This repository was archived by the owner on Mar 26, 2022. It is now read-only.
This repository was archived by the owner on Mar 26, 2022. It is now read-only.

bc-server runs as root - web server can't access recordings #3

@dseven

Description

@dseven

Me again. Hope the feedback is useful. Let me know if not, and I'll go away :)

So I found that I was unable to playback recordings, through either the remote client or web. This is because bc-server is running as root, the files (and subdirectories) are created with only owner and group access, and the web server (running as www-data) is not in the root group.

I found an old motherboard to install Ubuntu on to experiment with non-docker. There, I see that bc-server is running as the bluecherry user and group, and that www-data is a member of the bluecherry group, so it does have access to the recordings.

root@gwmobo:~# ls -l /var/lib/bluecherry/recordings/2019/12/20/000001
total 52440
-rw-rw---- 1 bluecherry bluecherry   165201 Dec 20 01:15 01-15-48.jpg
-rw-rw---- 1 bluecherry bluecherry 53525027 Dec 20 01:20 01-15-48.mkv
root@gwmobo:~# ps -fu bluecherry
UID        PID  PPID  C STIME TTY          TIME CMD
blueche+ 16203     1 47 01:04 ?        00:35:38 /usr/sbin/bc-server -s -u bluecherry -g bluecherry
root@gwmobo:~# id www-data
uid=33(www-data) gid=33(www-data) groups=33(www-data),4(adm),20(dialout),29(audio),44(video),999(bluecherry)
root@gwmobo:~#

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions