mirror of
https://github.com/linuxserver/docker-baseimage-alpine.git
synced 2026-02-20 00:47:04 +08:00
try always setting id and gid rather than test
This commit is contained in:
parent
38327507e5
commit
424bf23aa7
@ -1,11 +1,10 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
[[ -z $PGID ]] && PGID="911"
|
||||
[[ -z $PUID ]] && PUID="911"
|
||||
|
||||
PUID=${PUID:-911}
|
||||
PGID=${PGID:-911}
|
||||
|
||||
if [ ! "$(id -u abc)" -eq "$PUID" ]; then usermod -o -u "$PUID" abc ; fi
|
||||
if [ ! "$(id -g abc)" -eq "$PGID" ]; then groupmod -o -g "$PGID" abc ; fi
|
||||
groupmod -o -g "$PGID" abc
|
||||
usermod -o -u "$PUID" abc
|
||||
|
||||
echo "
|
||||
-------------------------------------
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user