This is a fork of gotenberg that changes the following:
- Added option to libreOffice route to convert document to plain text. Specifically made for rtf -> text conversions.
- Added route
gspreviewthat add conversions by GraphicsMagick and Ghostscript - Removed
chromiumandpdftk(including java) from Docker image
main: Keepmainbranch in sync with the main branch of the source repositorydev: Use as "main" branch for this fork
Specify text as output in the request body:
- outputFormat=<pdf, text> (default=pdf)
Example
curl --request POST -F files=@test.rtf -F "outputFormat=text" http://localhost:3002/forms/libreoffice/convert -o output.txt
Attention: is not set up to work with multiple files in the request.
Unless specified a PDF is converted to an png-image, all other files are converted to pdf.
Force operation by setting output format in request body:
- outputFormat=<auto, png, pdf> (default=auto)
As with other routes in gotenberg it's possible to convert multiple files in 1 request which will return the result in a zip-archive.
Specify x dimension (pixels) in request body:
- xsize= (default 1200 pixels)
Example:
curl --request POST -F "xsize=600" -F "outputFormat=auto" -F files=@test.pdf http://localhost:3002/forms/gspreview -o preview.png
(takes no extra arguments)
Example
curl --request POST -F "outputFormat=auto" -F files=@test1.tiff http://localhost:3002/forms/gspreview -o output.pdf
Testrunner is updated with tags so to not include removed parts
make test-unit
make test-integration
To only run our integration test
make test-prorenata
Set correct GOTENBERG_VERSION (defined in .env)
Run build script from gotenberg root path
make build
Creates image on prorenata/gotenberg:GOTENBERG_VERSION
(fold this part into a separate script)
Push images (Not possible on a normal docker user).
Example:
docker push prorenata/gotenberg:v8.24.0-prorenata-dev-amd64
docker push prorenata/gotenberg:v8.24.0-prorenata-dev-arm64
Create multi architecture manifest.
Example:
docker manifest create prorenata/gotenberg:v8.24.0-prorenata-dev --amend prorenata/gotenberg:v8.24.0-prorenata-dev-amd64 --amend prorenata/gotenberg:v8.24.0-prorenata-dev-arm64
docker manifest push prorenata/gotenberg:v8.24.0-prorenata-dev
- CHROMIUM_DISABLE_ROUTES: (Already disabled in docker images)
- API_ENABLE_DEBUG_ROUTE: Enables some debug features. Example:
curl --request GET http://localhost:3002/debug - GOTENBERG_ENABLE_PROMETHEUS: Enable prometheus
- Project fork documentation
- Document -> plain text conversion via libreOffice
- PDF <-> Image conversion via GraphicsMagick and Ghostscript
- Remove pdftk, java and chromium from Docker image
- Updated test suite to pass with removed modules
- Some changes to build scripts