# Run docker container in userspace

**URL:** <https://forum.rclone.org/t/run-docker-container-in-userspace/11734>\
**Category:** Help and Support\
**Created:** [September 11, 2019, 3:35am UTC](https://forum.rclone.org/t/run-docker-container-in-userspace/11734 "2019-09-11T03:35:17Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![matei.david](https://forum.rclone.org/letter_avatar_proxy/v4/letter/m/8c91f0/32.png) [@matei.david](https://forum.rclone.org/u/matei.david)\
**Post date:** [September 12, 2019, 1:17pm UTC](https://forum.rclone.org/t/run-docker-container-in-userspace/11734/7 "2019-09-12T13:17:33Z")

</div>

> [@ncw](#):
>
> Though I'd probably put the binary in `/bin`

I would suggest `/usr/local/bin` because it's something built locally (inside the image) not coming from standard Alpine packages.

> [@ncw](#):
>
> I wonder if we should also create a `/config` directory then set XDG\_CONFIG\_HOME in the image to be `/config` . This will cause rclone to make its config in `/config/rclone` and that would then make it easy to mount your own config `-v ~/.config/rclone:/config/rclone` regardless of the user settings.

Yes, that's exactly what I was thinking to suggest. I saw the error about 10 tries as well, but that one I didn't fully understand- Why does the move fail exactly? Clearly the container with uid=0 has all the permissions it would ever want. My best guess is it has to do with how Docker mounts single files, so that `/root/.rclone.conf` is marked as "special" somehow, but I'm not sure about this. If that's the case, yes, I would agree to make a `/config`, set the relevant environment variable to point there, and tell the user to mount their config dir there.

Can I try a PR against [rclone/Dockerfile at master · rclone/rclone · GitHub](https://github.com/rclone/rclone/blob/master/Dockerfile)?

---

_[View the full topic](https://forum.rclone.org/t/run-docker-container-in-userspace/11734)._
