When trying to stop or restart a docker container I\'m getting the following error message:
$ docker restart 5ba0a86f36ea Error response from daemon: Cannot rest
If you're on Ubuntu, make sure docker-compose isn't installed as snap. This will cause all kinds of random issues, including the above.
Remove the snap:
sudo snap remove docker-compose
And install manually from compose repository:
Docker compose installation instruction