From b30a2249c467a33075f076b05b1cb8e249febf20 Mon Sep 17 00:00:00 2001 From: Stian Buch Larsen Date: Sun, 10 May 2015 12:05:42 +0200 Subject: [PATCH] Fix for Not being able to use GID\UID that is already in use Added -o option to groupmod, to enable the useage of id's that allready exist in container os. (Fix for unraid) --- init/90_uid_gid_fix.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/init/90_uid_gid_fix.sh b/init/90_uid_gid_fix.sh index bc9c79f..a5a47e3 100644 --- a/init/90_uid_gid_fix.sh +++ b/init/90_uid_gid_fix.sh @@ -1,14 +1,14 @@ #!/bin/bash -if [ ! "$(id -u plex)" -eq "$PUID" ]; then usermod -u "$PUID" plex ; fi -if [ ! "$(id -g plex)" -eq "$PGID" ]; then groupmod -g "$PGID" plex ; fi +if [ ! "$(id -u abc)" -eq "$PUID" ]; then usermod -u "$PUID" abc ; fi +if [ ! "$(id -g abc)" -eq "$PGID" ]; then groupmod -o -g "$PGID" abc ; fi echo " ----------------------------------- -PLEX GID/UID +Plex GID/UID ----------------------------------- -Plex uid: $(id -u plex) -Plex gid: $(id -g plex) +Plex uid: $(id -u abc) +Plex gid: $(id -g abc) ----------------------------------- Plex will now continue to boot. "