This should no longer happen (since v2.2.0.0), see here
If you are using Docker for Windows, this error can happen if you have recently changed your password.
How to fix:
- First make sure to delete the broken container’s volume
docker rm -v <container_name>
Update: The steps below may work without needing to delete volumes first. - Open Docker Settings
- Go to the “Shared Drives” tab
- Click on the “Reset Credentials…” link on the bottom of the window
- Re-Share the drives you want to use with Docker
- You should be prompted to enter your username/password
- Click “Apply”
- Go to the “Reset” tab
- Click “Restart Docker”
- Re-create your containers/volumes