Replies: 1 comment 2 replies
-
Hi @Reklund3 Thanks for your question. I must admit I have never used the graalvm feature myself (unfortunately 😢 ).
That's partially correct. Only if you configure the If you do containerBuildImage := None docker shouldn't be involved.
That is possibly true. It may that you run the docker daemon as root thus the resulting output is also root? I mostly use docker for local development, but not in prod, but IIRC there are different permission strategies to run the docker daemon that also affects the generated output. |
Beta Was this translation helpful? Give feedback.
-
I have been working with the GraalVM native image plugin and happened across an issue with file permissions for the exported executable.
OS: Linux Ubuntu Bionic 18.04
When I run
graalvm-native-image:packageBin
the resulting executable ends up in the projects target folders with permission ofroot:root
instead of myuser:group
.Based on the code, my understanding is that the process uses a docker image to build the native image in and then copies the result out to my target folder. I believe that the root permissions are coming from the docker containers permissions that are being applied to the built executable before being copied to my host. This is cause the executible to have root:root on my host.
Is there a way to provide a user to the packageBin command? I think there is a way to query for the uid:gid of the active user and start docker containers so that the internal processes would run as those id's. Would this be something that we could open to a PR as a feature request?
@muuki88
Beta Was this translation helpful? Give feedback.
All reactions