Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add chown configuration parameter to set groupId and userId for files. #892

Closed
6 tasks
coollog opened this issue Aug 28, 2018 · 2 comments
Closed
6 tasks

Comments

@coollog
Copy link
Contributor

coollog commented Aug 28, 2018

NOT READY

Regards #727

Add a configuration to jib-maven-plugin/jib-gradle-plugin that can define the userid/groupid to set for the files we build into the container, similar to how Dockerfile's COPY --chown works. The container configuration User field should also be set accordingly.

chown can either be a single uid or a string of the form uid:gid.

So, for example, in your case, the configuration could look something like:

Maven:

<configuration>
  ...
  <container>
    <chown>10:11</chown>
  </container>
</configuration>

Gradle:

jib.container.chown = 10000

Tasks:

  • Add OwnerGroup to represent a pair of user id and group id (group id defaults to user id if not given).
  • Add User field to ContainerConfigurationTemplate.
  • Add OwnerGroup to BuildConfiguration.
  • Use OwnerGroup to build the layer files.
  • Add jib-maven-plugin chown parameter.
  • Add jib-gradle-plugin chown parameter.
@coollog coollog added this to the v0.9.11 milestone Aug 28, 2018
@coollog coollog removed this from the v0.9.11 milestone Aug 28, 2018
@coollog
Copy link
Contributor Author

coollog commented Aug 29, 2018

Closing unless found necessary again.

@coollog coollog closed this as completed Aug 29, 2018
@chanseokoh
Copy link
Member

Just FTR: files are already readable and possibly executable for any, so it doesn't seem necessary to set user and group IDs. At least we don't see a use case for it for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants