Try the fastest and simplest way to install ONLYOFFICE

Need some help clarifying from devs or hackers

Questions/problems on Docker

Need some help clarifying from devs or hackers

Postby Nalaurien » Sun Mar 05, 2017 7:59 am

So im trying to understand how the standards are set up here... but it will take a bit of explaining, anyone with insight would be appreciated.

so running the docker install with no mail server on an ubuntu 16 server. works fine, everything is running. But i dont want to just run this on that server, i want other containers on it and i dont always want onlyoffice to be on port 80. so i start scrubbing through the code of the install.

so heres the containers currently running:
Code: Select all
<community server containerID>
onlyoffice/communityserver:8.9.2.27
0.0.0.0:80->80/tcp
0.0.0.0:443->443/tcp
3306/tcp
5280/tcp
9865-9866/tcp
9871/tcp
9882/tcp
0.0.0.0:5222->5222/tcp
9888/tcp
onlyoffice-community-server


<document server conatinerID>
onlyoffice/documentserver:4.2.10.10
80/tcp
443/tcp


so when we look in opensource-install.sh (the file that they point to to install the dockerized environment) we see an install script downloaded and run, install.sh
so lets look through that.

at lines 18+ we find:
Code: Select all
COMMUNITY_CONTAINER_NAME="onlyoffice-community-server";
DOCUMENT_CONTAINER_NAME="onlyoffice-document-server";
MAIL_CONTAINER_NAME="onlyoffice-mail-server";
CONTROLPANEL_CONTAINER_NAME="onlyoffice-control-panel";

COMMUNITY_IMAGE_NAME="onlyoffice4enterprise/communityserver-ee";
DOCUMENT_IMAGE_NAME="onlyoffice4enterprise/documentserver-ee";
MAIL_IMAGE_NAME="onlyoffice/mailserver";
CONTROLPANEL_IMAGE_NAME="onlyoffice4enterprise/controlpanel-ee";


ok so I have a question, is the community edition just the educational edition or visa versa? because onlyoffice/ dockerhub has all of these servers listed but if i navigate to onlyoffice4enterprise/ in docker hub all i see there are the -ee versions of all the doc server the community server and control panel.

so then what are the servers in the dockerhub onlyoffice/ are they the paid versions? seemed backwards, i would expect the onlyoffice4enterprise/ hub to have the paid versions...

ok so we keep going, through alot of directory creation and version checking, and we come to the server installs.
well only do the document server, since all of the dockerized images are pretty much the same process.

at line 759 we see:
Code: Select all
<blah...blah>

sudo docker run --net onlyoffice -i -t -d --restart=always --name ${DOCUMENT_CONTAINER_NAME} ${DOCUMENT_SERVER_ADDITIONAL_PORTS} \
-v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data \
-v /app/onlyoffice/DocumentServer/logs:/var/log/onlyoffice \
-v /app/onlyoffice/DocumentServer/fonts:/usr/share/fonts/truetype/custom \
${DOCUMENT_IMAGE_NAME}:${DOCUMENT_VERSION}


ok cool, so it appears that the docker environment is mounting the directories it created earlier.
Next question; so if the mounted directories are how the multiple docker images are communicating to each other, that would explain the lack of any forwarded ports on the document server docker image, but then... why are ports open in the docker image at all?

also, in community server docker image, what is 5222 for? its official listing is xmpp port, so is this for chat functionality in the community section of the portal?

Code: Select all
make_directories () {
   sudo mkdir -p "/app/onlyoffice/setup";

   sudo mkdir -p "/app/onlyoffice/DocumentServer/data";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/logs/documentserver/FileConverterService";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/logs/documentserver/CoAuthoringService";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/logs/documentserver/DocService";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/logs/documentserver/SpellCheckerService";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/logs/documentserver/LibreOfficeService";
   sudo mkdir -p "/app/onlyoffice/DocumentServer/fonts";

   sudo mkdir -p "/app/onlyoffice/MailServer/data/certs";
   sudo mkdir -p "/app/onlyoffice/MailServer/logs";
   sudo mkdir -p "/app/onlyoffice/MailServer/mysql";

   sudo mkdir -p "/app/onlyoffice/CommunityServer/data";
   sudo mkdir -p "/app/onlyoffice/CommunityServer/logs";
   sudo mkdir -p "/app/onlyoffice/CommunityServer/mysql";

   sudo mkdir -p "/app/onlyoffice/ControlPanel/data";
   sudo mkdir -p "/app/onlyoffice/ControlPanel/logs";
   sudo mkdir -p "/app/onlyoffice/ControlPanel/mysql";
}


and finally, it seems the mount points are all handling everything, which is why container 2 can access data from container 1 without talking to it. So does this mean if i copy these directories in their entirety i can effectivly make my own backup system for community edition ;) ? since it doesnt come with one (or at least the documentation says its a feature of the enterprise edition)

anyway, anyone with any info would be appreciated. :D
Nalaurien
 
Posts: 2
Joined: Sun Mar 05, 2017 12:21 am

Re: Need some help clarifying from devs or hackers

Postby Maxim » Mon Mar 06, 2017 9:25 am

Hello Nalaurien!
i dont always want onlyoffice to be on port 80
- Unfortunately for now there is no way to use custom ports, but we are working on it.
is the community edition just the educational edition or visa versa?
- It's free but has some of limitations like using one core only, 20 simultaneous
connections (sessions), the 21 conncetion works in view mode only. There is no Control Panel in Community Edition, but in Enterprise it is.
so then what are the servers in the dockerhub onlyoffice/ are they the paid versions?
- Enterprise Edition is paid version
what is 5222 for?
- for chat, jabber client
why are ports open in the docker image at all?
- Docker containers communicate with each other through internet using 80 and 443 ports
if i copy these directories in their entirety i can effectivly make my own backup system for community edition ;) ?
- When you copy /app/onlyoffice you create a backup.
Maxim
 
Posts: 495
Joined: Tue Oct 11, 2016 2:34 pm

Re: Need some help clarifying from devs or hackers

Postby Nalaurien » Tue Mar 07, 2017 6:16 am

ok so what your saying is in the dockerized network the port 80 cannot be changed, but from my docker images list here the only ports i see bound to the host machine are 80 443 and 5222. if there is no mail server.

so does something break if i just:
$ docker run -p 90:80 <communityserver>
??

perhaps its just my misunderstanding of dockerized containers, but i guess the exposed ports in the container are only available on 127.0.0.1 and only accessible from another system if they are bound to the host machine port with run command?
Nalaurien
 
Posts: 2
Joined: Sun Mar 05, 2017 12:21 am


Return to Docker Version

Who is online

Users browsing this forum: No registered users and 2 guests