Skip to content

Respect umaskΒ #320

@dlitz

Description

@dlitz

Output of rest-server --version

rest-server version rest-server 0.13.0 compiled with go1.22.5 on linux/amd64

What should rest-server do differently?

It should respect the process umask when writing files, or do something like this, as was done in restic proper.

What are you trying to do? What is your use case?

I'm trying to do remote rsync backups of my rest-server repository with a user that only has read-only access to the repository. I'm using a POSIX ACL to grant access to the backup user, but POSIX ACLs don't work unless the files are group-accessible (in my case, group-readable). Setting UMask=007 in my rest-server.service doesn't work, despite the comment there. (I confirmed using /proc/[pid]/status that the process Umask is being set correctly.)

Right now, I have to run a cron job that periodically resets the repo permissions every 60 seconds. That creates a race-condition with the backup process and shouldn't be necessary.

Did rest-server help you today? Did it make you happy in any way?

Yes! I use it every day to back up everything.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions