OnlyOffice compiled with Mobile Edit Back

Edit 03/06/2020 : Now 5.5.3 is live.
Today a new milestone has been past : 1K downloads of this Docker Container, you are amazing everyone !
——————————-
OnlyOffice Document Server with a 100 simultaneous connections and Mobile Edition !

image


Alright i built a Docker Repository where i put my working image. Source code is at the end of this HOW TO.

So let’s start :
docker pull nemskiller007/officeunleashed
Will download my image
Let’s run it :
docker run -i -t -d -p 8000:80 --restart=always nemskiller007/officeunleashed
Do a : docker ps -a in order to find your CONTAINER_ID or CONTAINER_NAME
Lets modify a file for having a password protected OnlyOffice :
docker exec -it CONTAINER_ID /bin/bash

nano /out/linux_64/onlyoffice/documentserver/server/Common/config/default.json

Go on line 155 and replace every string with secret written in it with your own password :
example : "browser": {"string": "ItsMyPassw0rdBro", "file": "", "tenants": {}},

Then on line 163 to 170 change all false by true
example

        "request": {
       "inbox": true,   
    "outbox": true
                           }

Save and quit, and quit the container by an exit
Shutdown the container and restart it
docker stop CONTAINER_ID
docker start CONTAINER_ID

Here is the nginx conf file you have to use (replace office.MYDOMAIN.COM by your own FQDN):

upstream docservice {
  server office.MYDOMAIN.COM:8000;
}

map $http_host $this_host {
    "" $host;
    default $http_host;
}

map $http_x_forwarded_proto $the_scheme {
     default $http_x_forwarded_proto;
     "" $scheme;
}

map $http_x_forwarded_host $the_host {
    default $http_x_forwarded_host;
    "" $this_host;
}

map $http_upgrade $proxy_connection {
  default upgrade;
  "" close;
}

proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $proxy_connection;
proxy_set_header X-Forwarded-Host $the_host;
proxy_set_header X-Forwarded-Proto $the_scheme;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;


server {
  server_tokens off;
  server_name office.MYDOMAIN.COM;
  location / {
    proxy_pass http://docservice;
    proxy_http_version 1.1;
  }

  listen 0.0.0.0:80;
  listen [::]:80;
  server_name office.MYDOMAIN.com;
   
}

Then reload nginx and ask an ssl cert to letsencrypt.
Install the « ONLYOFFICE » app and in the onlyoffice admin panel type https://office.MYDOMAIN.COM and the secret password you created.
If you have on the same host nextcloud and the onlyoffice docker you have to modify the file /etc/hosts by adding this line
127.0.0.1 office.MYDOMAIN.COM

If you want the source code : https://github.com/warnerbryce/DocumentServer
If you want the files compiled without the Docker Container : https://cloud.werry.ovh/s/yrajzsbqZroxzqx/download

I will try to keep this up to date with the next versions, but if someone wants to help me, i can share the building process (very complicated). @jospoortvliet @rakekniven

15 Likes

Please make sure you document any quirks :slight_smile:

Oh and any chance you have a ARM64 device to test compiling it there?

HOW TO added.
Have fun

1 Like

Source Code and Built code added.

I suggest you post a diff and open a repository. That makes it easier :slight_smile:

you mean on GitHub ?
I use this for building my code : https://github.com/ONLYOFFICE/web-apps/pull/335
but i really don’t know how to make a diff.

Thanks, I was hopeful for a moment that OnlyOffice themselves had done this. Sigh.

immanuelfodor replied on Mar 19

Yeah, but maintaining a fork with possibly growing differences later on won’t be fun

For the moment they didn’t implement breaking build if you have old web-apps files.

Instead of that you could run supervisorctl restart all inside the container if you are already inside it in a shell.

Inside my container the command supervisorctl doesn’t exist…

Is there a way to automate this process at all. For example a git repository with source code that could be built with travis and then pushed to docker hub?

The GitHub Repository is ready :


I need assistance to work with Travis and Docker Hub,
For the moment i build with the OnlyOffice/build_tools on a Ubuntu 14.04 then i create the Docker Container and then i upload it

4 Likes

Ok – so Travis will build everything upon any new github push from you. If you link Dockerhub to the github where the container ends up – it will automatically build if it has a dockerfile I believe as well.

My only problem is that I don’t know your instructions for building.

Hello nemskiiler,

whs you didn’t have no more information at hub.docker?

https://hub.docker.com/r/nemskiller007/officeunleashed

Such as this:

https://hub.docker.com/_/nextcloud

I don’t feel good if i user docker container without more information.

Thank’s for your work.

nc-kay

I will do a copy paste of this HOW TO on the Docker Hub description.

The Dockerfile is very important to trust your Docker Container.
Before i use a Docker Container i look at the Dockerfile.

Look at this:

https://hub.docker.com/r/diginc/pi-hole/dockerfile

Thank’s

nc-kay

I too would like to see a dockerfile

I used this for building the Docker Container with my compiled files :

with this command :
docker build --tag officeunleashed Ubuntu18.04

Hi @Nemskiller,

We are using the OnlyOffice docker in our nextcloud application. But we can’t edit the documents or excel sheets in mobile app or mobile browser. The keyboard is not available while editing in mobile. What may be the issue and please help me to to resolve it. I am attaching the screenshots of documents in the mobile.

@skumar I don’t have this problem.
Look at this image i am on LineageOS 16.
Are you using my own onlyoffice docker like you can use in my HOW TO, or another onlyoffice docker container you get elsewhere ?

I just revert back code from the time it work on iOS and Android.