PUID GUID

This commit is contained in:
Alexandre
2023-04-02 13:23:57 +02:00
parent 0786fb6c21
commit 257ad11613
2 changed files with 4 additions and 4 deletions

View File

@@ -47,8 +47,8 @@ if bashio::config.has_value "PUID" && bashio::config.has_value "PGID"; then
PGID="$(bashio::config "PGID")" PGID="$(bashio::config "PGID")"
bashio::log.blue "User UID: $PUID" bashio::log.blue "User UID: $PUID"
bashio::log.blue "User GID : $PGID" bashio::log.blue "User GID : $PGID"
groupmod -o -g "$PGID" abc &>/dev/null || true id -u abc &>/dev/null || usermod -o -u "$PUID" abc &>/dev/null || true
usermod -o -u "$PUID" abc &>/dev/null || true id -g abc &>/dev/null || groupmod -o -g "$PGID" abc &>/dev/null || true
bashio::log.blue \ bashio::log.blue \
'-----------------------------------------------------------' '-----------------------------------------------------------'
fi fi

View File

@@ -5,8 +5,8 @@ if bashio::config.has_value "PUID" && bashio::config.has_value "PGID"; then
PUID="$(bashio::config "PUID")" PUID="$(bashio::config "PUID")"
PGID="$(bashio::config "PGID")" PGID="$(bashio::config "PGID")"
bashio::log.green "Setting user to $PUID:$PGID" bashio::log.green "Setting user to $PUID:$PGID"
groupmod -o -g "$PGID" abc id -u abc &>/dev/null || usermod -o -u "$PUID" abc || true
usermod -o -u "$PUID" abc id -g abc &>/dev/null || groupmod -o -g "$PGID" abc || true
fi fi
echo "Updating permissions..." echo "Updating permissions..."