What is the purpose and benefit of using the --system
option when adding a
user, or even a group?
I'd like to know why I'm seeing this added to many Docker containers and recommended as a best practice?
For example sake I'm adding a non-root user to an Alpine Docker container for use when developing and again for runtime.
The current versions I'm using are:
- adduser version is 3.118, and the Alpine adduser man
- Alpine version is 3.12
- Docker v19.03.13 on Windows 10 (20H2 update)
The man page reads "Create a system user", O.K. but what do you get as a system
user? Or being in a system group when using addgroup -S
.
I do not have a System Admin background, so I'm not sure what that means and would like clarity as to when I should use this?
Some Other Reading
Searching Google has provide some insight but no way to verify what I've read.
That it does not ask you to set a password for the user, but then I can use use
--disabled-password
for that.
I then found this post here, I got that its for organization purposes, but does not help me much either. I'm only a little bit more clearm, yet not confident enough to explain when to use them.
What's the difference between a normal user and a system user?