The problem was indeed do with HOME not being correctly set, adding -H to the sudo command for the multisite migrate fixed it, as detailed here:
https://meta.discourse.org/t/multisite-configuration-with-docker/14084/184?u=yaxu
The problem was indeed do with HOME not being correctly set, adding -H to the sudo command for the multisite migrate fixed it, as detailed here:
https://meta.discourse.org/t/multisite-configuration-with-docker/14084/184?u=yaxu