CoreBOSBB
Unoconv server settings - Printable Version

+- CoreBOSBB (https://discussions.corebos.org)
+-- Forum: Support (https://discussions.corebos.org/forumdisplay.php?fid=17)
+--- Forum: Administrator Support (https://discussions.corebos.org/forumdisplay.php?fid=8)
+--- Thread: Unoconv server settings (/showthread.php?tid=2596)

Pages: 1 2


Unoconv server settings - geraldbigot - 02-22-2023

I installed unoconv like explained in the gendoc documentation.
I tested it in command line on my server : it produces pdf export well
I put unoconv listening : unoconv --listener &
I put my convert_url in global variable

When I'm trying to export pdf from coreBOS it generated 0 ko pdf file.

What am I doing wrong ?


RE: Unoconv server settings - joebordes - 02-22-2023

you installed unoconv in the server, not the docker container of unoconv.

I mean there are two ways of configuring unoconv, one is installing all the software directly in your server and the other is launching the unoconv docker container.

the global variable is for the docker container, not for the server install

unoconv has been deprecated, you must use unoserver and the global variable GenDoc_URL_UnoServer

we are using this docker container: https://github.com/lynxtaa/unoserver-web


RE: Unoconv server settings - geraldbigot - 02-22-2023

(02-22-2023, 01:05 PM)joebordes Wrote: you installed unoconv in the server, not the docker container of unoconv.

I mean there are two ways of configuring unoconv, one is installing all the software directly in your server and the other is launching the unoconv docker container.

the global variable is for the docker container, not for the server install

unoconv has been deprecated, you must use unoserver and the global variable GenDoc_URL_UnoServer

we are using this docker container:  https://github.com/lynxtaa/unoserver-web

I just tried to create this GV :  https://github.com/lynxtaa/unoserver-web as GenDoc_URL_UnoServer
but I obtained this error opening exported pdf :

"PDF document is damaged"


RE: Unoconv server settings - joebordes - 02-22-2023

you have to install the docker container as a service and set the global variable to the IP of the docker container


RE: Unoconv server settings - joebordes - 02-22-2023

docker run -d -p 3000:3000 lynxtaa/unoserver-web:latest


RE: Unoconv server settings - geraldbigot - 02-22-2023

I installed the docker container even I'm not sure. I never used docker before today.
How can I check unoserver is well installed and configured ?

Here is the result of "sudo docker image ls"

REPOSITORY              TAG       IMAGE ID       CREATED         SIZE
lynxtaa/unoserver-web   latest    488c9d777081   5 weeks ago     912MB
hello-world             latest    feb5d9fea6a5   17 months ago   13.3kB


RE: Unoconv server settings - joebordes - 02-22-2023

try `docker ps` that should show you the process running

then you can try the command in the repo

curl \
--request POST 'http://localhost:3000/convert/pdf' \
--form 'file=@"/path/to/file.docx"' \
-o my.pdf

finally, try using that same URL `http://localhost:3000`


RE: Unoconv server settings - geraldbigot - 02-22-2023

(02-22-2023, 03:16 PM)joebordes Wrote: try `docker ps`  that should show you the process running

then you can try the command in the repo

curl \
--request POST 'http://localhost:3000/convert/pdf' \
--form 'file=@"/path/to/file.docx"' \
-o my.pdf

finally, try using that same URL `http://localhost:3000`

docker ps : CONTAINER ID   IMAGE                          COMMAND                  CREATED             STATUS             PORTS                    NAMES

682123ab3dd8   lynxtaa/unoserver-web:latest   "/tini -- node -r do…"   About an hour ago   Up About an hour   0.0.0.0:3000->3000/tcp   jovial_goodall

OK



curl --request POST 'http://localhost:3000/convert/pdf' --form 'file=@"/home/gb/comp.odt"' -o my.pdf  :

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current

                                 Dload  Upload   Total   Spent    Left  Speed
100  122k  100 71831  100 53308  12082   8966  0:00:05  0:00:05 --:--:-- 19195

OK

but when I click "Export PDF" in coreBOS :

"Le type de fichier document texte brut (text/plain) n’est pas pris en charge"


RE: Unoconv server settings - joebordes - 02-22-2023

what value does the global variable have?


RE: Unoconv server settings - geraldbigot - 02-22-2023

I tested with http://localhost:3000 and also http://myserverIP:3000