qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] docs/devel/testing: Add -a option to usermod command on docker setup
@ 2019-02-07 18:43 Murilo Opsfelder Araujo
  2019-02-08 17:32 ` Alex Bennée
  0 siblings, 1 reply; 2+ messages in thread
From: Murilo Opsfelder Araujo @ 2019-02-07 18:43 UTC (permalink / raw)
  To: qemu-devel
  Cc: mopsfelder, Murilo Opsfelder Araujo, Philippe Mathieu-Daudé,
	Fam Zheng, Alex Bennée, Daniel P. Berrangé, Cleber Rosa,
	qemu-trivial

The option -G of usermod command will remove user from other groups
not listed, i.e.: $USER will belong only to group 'docker' after
following the documentation as is.

>From usermod(8) manual page:

    If the user is currently a member of a group which is not listed,
    the user will be removed from the group. This behaviour can be
    changed via the -a option, which appends the user to the current
    supplementary group list.

This patch improves the situation by adding the -a option to the
usermod command, which will just append user to the supplementary
group list.

Cc: qemu-trivial@nongnu.org
Signed-off-by: Murilo Opsfelder Araujo <muriloo@linux.ibm.com>
---
 docs/devel/testing.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/devel/testing.rst b/docs/devel/testing.rst
index 18e2c0868a..135743a2bf 100644
--- a/docs/devel/testing.rst
+++ b/docs/devel/testing.rst
@@ -301,7 +301,7 @@ An alternative method to set up permissions is by adding the current user to
 .. code::
 
   $ sudo groupadd docker
-  $ sudo usermod $USER -G docker
+  $ sudo usermod $USER -a -G docker
   $ sudo chown :docker /var/run/docker.sock
 
 Note that any one of above configurations makes it possible for the user to
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] docs/devel/testing: Add -a option to usermod command on docker setup
  2019-02-07 18:43 [Qemu-devel] [PATCH] docs/devel/testing: Add -a option to usermod command on docker setup Murilo Opsfelder Araujo
@ 2019-02-08 17:32 ` Alex Bennée
  0 siblings, 0 replies; 2+ messages in thread
From: Alex Bennée @ 2019-02-08 17:32 UTC (permalink / raw)
  To: Murilo Opsfelder Araujo
  Cc: qemu-devel, mopsfelder, Philippe Mathieu-Daudé, Fam Zheng,
	Daniel P. Berrangé, Cleber Rosa, qemu-trivial


Murilo Opsfelder Araujo <muriloo@linux.ibm.com> writes:

> The option -G of usermod command will remove user from other groups
> not listed, i.e.: $USER will belong only to group 'docker' after
> following the documentation as is.
>
> From usermod(8) manual page:
>
>     If the user is currently a member of a group which is not listed,
>     the user will be removed from the group. This behaviour can be
>     changed via the -a option, which appends the user to the current
>     supplementary group list.
>
> This patch improves the situation by adding the -a option to the
> usermod command, which will just append user to the supplementary
> group list.
>
> Cc: qemu-trivial@nongnu.org
> Signed-off-by: Murilo Opsfelder Araujo <muriloo@linux.ibm.com>

Queued to testing/next, thanks.

> ---
>  docs/devel/testing.rst | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/docs/devel/testing.rst b/docs/devel/testing.rst
> index 18e2c0868a..135743a2bf 100644
> --- a/docs/devel/testing.rst
> +++ b/docs/devel/testing.rst
> @@ -301,7 +301,7 @@ An alternative method to set up permissions is by adding the current user to
>  .. code::
>
>    $ sudo groupadd docker
> -  $ sudo usermod $USER -G docker
> +  $ sudo usermod $USER -a -G docker
>    $ sudo chown :docker /var/run/docker.sock
>
>  Note that any one of above configurations makes it possible for the user to


--
Alex Bennée

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-02-08 17:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-07 18:43 [Qemu-devel] [PATCH] docs/devel/testing: Add -a option to usermod command on docker setup Murilo Opsfelder Araujo
2019-02-08 17:32 ` Alex Bennée

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).