Permission denied .local with build on laptop

I’m experiencing in a problem that I don’t understand well how to resolve, after build my image from my laptop with repo2docker and then try to start it from Jhub it goes in Back-off restarting cause it raise and exception

File "/srv/conda/envs/notebook/lib/python3.8/", line 223, in makedirs
    mkdir(name, mode)
PermissionError: [Errno 13] Permission denied: '/home/fbalicchia/.local' 

I’ve already tried some flags like --user-name or adding --env but nothing the problem continues to appear. I’m using repo2docker version 0.11.0.
Could you tell me some tips please to resolve this issue ?

Thanks for help


1 Like

Hi the problem seems to happen only on MacOS box. On Linux box it works for me but seems at moment of bootstrap it it used as $HOME the user that make the build

How are you loading the image into JupyterHub? Are you able to share your configuration?

Have you tried building the image with --user-id 1000? Permission denied is most likely due to the image or volume UID not matching the runtime UID of the container. These are set separately by repo2docker and the Spawner (which Spawner are you using?). The repo2docker default is to use the calling user UID (default: 501 for first user on mac, 1000 on linux). An additional source of permissions could be the volume mount owner and permissions, which is also a Spawner configuration parameter.

Thanks for response using settings --user-id resolve my problem