Page 1 of 1

document server in docker is not able to find documents

Posted: Fri Aug 09, 2019 7:35 am
by manucastro
Hi to all,
I have built a small document-manager based in Python (bottle). Since I sent to the Document-server the document id and the local URL (on my computer) the document-server is not able to find and open this document. May I have to put th documents in an other location? How do the docker container (document-server) know where is the document place on?

After clicking the button my piece of code calls to a javascript function like this:

Code: Select all

 editor = new DocsAPI.DocEditor("placeholder",
            {
                documentType: "text",
                document: {
                    fileType: "odt",
                    url: "http://localhost:8080/files/ex2.odt",
                    title: filename,
                    key: filename + '_key'
                },
                editorConfig: {mode: 'view'}, 
                height: "100%",
                width: "100%"
            });

But the onlyoffice server is not searching in the path I sent it through javascript.
Ah my document-server was started with

Code: Select all

docker run -it -d -p 80:80 --name=only-office  -v /app/onlyoffice/DocumentServer/logs:/var/log/onlyoffice  -v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data  -v /app/onlyoffice/DocumentServer/lib:/var/lib/onlyoffice -v /app/onlyoffice/DocumentServer/db:/var/lib/postgresql  onlyoffice/documentserver
Nothing mysterious here.
Any idea with that?

Re: document server in docker is not able to find documents

Posted: Sun Aug 11, 2019 6:51 pm
by Maxim
Hello!
I'm sure that your URL is wrong, you cannot use this url like "http://localhost:8080/files/ex2.odt".