I can use the current username in a pom.xml
-file with ${user.name}
, but is there a way to get the uid (userid)?
I use exec-maven-plugin
and add arguments to a execution. I've tried different things (${env.UID}
, ${user.id}
, $UID
), but neither work.
I need it to start a process in docker that writes files to a shared directory. If I don't start with the -u
-parameter all files will belong to root
.
The configuration is like:
<configuration>
<executable>docker</executable>
<arguments>
<argument>run</argument>
<argument>-u</argument>
<argument>$UID</argument>
<argument>...</argument>
</arguments>
</configuration>