> An aspect of Docker that I don’t really like is that inside the container you are root by default
PSA: everyone should turn on the userns option in docker daemon settings. It messes with volume mounts but you can turn it off on a per container basis (userns=host) or arrange a manual uid mapping for the mounts.
https://docs.docker.com/v17.12/engine/security/userns-remap/