summaryrefslogtreecommitdiffstats
path: root/bash-completion
diff options
context:
space:
mode:
authorLaurent Vivier2018-10-05 13:09:30 +0200
committerKarel Zak2018-11-12 11:52:15 +0100
commitf0af42b51761428bdd821b31381fbfa1346f6782 (patch)
treed470ecd3f56b55267523151531f95fffecf04659 /bash-completion
parentunshare: allow to set a new root (diff)
downloadkernel-qcow2-util-linux-f0af42b51761428bdd821b31381fbfa1346f6782.tar.gz
kernel-qcow2-util-linux-f0af42b51761428bdd821b31381fbfa1346f6782.tar.xz
kernel-qcow2-util-linux-f0af42b51761428bdd821b31381fbfa1346f6782.zip
unshare: allow to set user ID and group ID
This patch introduces two new parameters to set the user ID and the group ID of the program to be executed. Setting group ID also drops supplementary groups. The option names used are the same as for nsenter, -S, --setuid and -G, --setgid. Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Diffstat (limited to 'bash-completion')
-rw-r--r--bash-completion/unshare4
1 files changed, 3 insertions, 1 deletions
diff --git a/bash-completion/unshare b/bash-completion/unshare
index 64aea6784..10afffe19 100644
--- a/bash-completion/unshare
+++ b/bash-completion/unshare
@@ -35,7 +35,9 @@ _unshare_module()
--help
--version
--root
- --wd"
+ --wd
+ --setuid
+ --setgid"
COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
return 0
;;