If you have an external MySQL server installed on your machine (or on another computer), you can connect it executing the following command:
sudo docker run --net onlyoffice -i -t -d --restart=always --name onlyoffice-community-server -p 80:80 -p 443:443 -p 5222:5222 \
-e MYSQL_SERVER_HOST="127.0.0.1"\
-e MYSQL_SERVER_PORT="3306"\
-e MYSQL_SERVER_DB_NAME=onlyoffice\
-e MYSQL_SERVER_USER=onlyoffice_user\
-e MYSQL_SERVER_PASS=onlyoffice_pass\
-v /app/onlyoffice/CommunityServer/data:/var/www/onlyoffice/Data \
-v /app/onlyoffice/CommunityServer/logs:/var/log/onlyoffice \
onlyoffice/communityserver
Where "127.0.0.1"
is the address for the installed MySQL server (leave it as "127.0.0.1"
in case MySQL server is installed on the same computer as ONLYOFFICE Groups or change it to the actual MySQL server IP address).
You might need to edit the parameters entered for the above command in case you previously changed them when you installed the external MySQL database.