document server in docker is not able to find documents

Questions/problems on Docker
Post Reply
manucastro
Posts: 1
Joined: Thu Aug 01, 2019 5:30 pm

document server in docker is not able to find documents

Post by manucastro » Fri Aug 09, 2019 7:35 am

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?
Attachments
not-found.jpeg
not-found.jpeg (166.11 KiB) Viewed 30 times

Maxim
Posts: 2017
Joined: Tue Oct 11, 2016 2:34 pm

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

Post by Maxim » Sun Aug 11, 2019 6:51 pm

Hello!
I'm sure that your URL is wrong, you cannot use this url like "http://localhost:8080/files/ex2.odt".

Post Reply