docker-workflow-plugin icon indicating copy to clipboard operation
docker-workflow-plugin copied to clipboard

JENKINS-45473 Run user inside with all groups membership.

Open mikeslattery opened this issue 5 years ago • 0 comments

Adds all groups using --group-add.

When using docker.inside() or a Docker agent, --user is passed to assume the Jenkins user's identity, but this only works for the user id and primary group id. This patch adds all additional groups (by id) the user may belong to.

The primary motivation is the lack of membership in the "docker" group inside the agent, which makes running docker commands not possible without some kind of dirty workaround.

mikeslattery avatar May 20 '19 20:05 mikeslattery