First you need to stop the ONLYOFFICE DocSpace Docker containers. This can be done using the Docker stop
command:
sudo docker container stop $(docker container ls -q --filter name=onlyoffice-*)
To remove the stopped containers use the following command:
sudo docker rm $(docker ps -aq --filter name=onlyoffice-*)
The names of all the containers present in the system can be found using the command:
sudo docker ps -a
You can also remove all the Docker containers from your system using the following command:
sudo docker rm -f $(sudo docker ps -aq)
Warning This command will remove ALL the containers immediately. Please do not use it if you have other containers running that you do not want to remove.