jodconverter / docker-image-jodconverter-examples

Docker image with jodconverter + libreoffice for document conversion through a REST api
https://github.com/sbraconnier/jodconverter
MIT License
72 stars 32 forks source link

Run containers without root privileges #16

Closed alangecker closed 2 years ago

alangecker commented 2 years ago

for increased security :)

closes #15

EugenMayer commented 2 years ago

Thank you for the contribution! Really looking to merge that one

Should we consider using gosu or alikes instead of just USER?

EugenMayer commented 2 years ago

To elaborate a little more, i see that:

alangecker commented 2 years ago

@EugenMayer It works now with gosu and is rebased onto the current master ;)

EugenMayer commented 2 years ago

Did you actually test any of the docker images building on this on over at https://github.com/EugenMayer/officeconverter ?

Since they heavily depend on this build, this will be the mandatory test, jodconverter:base is what is used there.

I assume rootless should work, since it just wrapps the java call - the question is if this somehow affects the startup of the headless libreoffice

EugenMayer commented 2 years ago

Any new s hew @alangecker ? Thank you for the effort

alangecker commented 2 years ago

sorry, didn't manage to find the time to check that :)

I did it now and officeconverter seems to work flawlessly 🎉. I also ran the tests make test without any issues

I only realized that I removed the line CMD ["--spring.config.additional-location=/etc/app/"] due to an error and accidentally commited it in this PR which might break it for people using an additional config. I readded the line now, but took the opportunity to add an additional optional: prefix as suggested by @lightweight in this issue: https://github.com/bigbluebutton/docker/issues/178

It's definitely not clean to have an unrelated change in the same PR, but hope it's okay^^

EugenMayer commented 2 years ago

Thank you for your contribution!