mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-09 00:55:58 +02:00
Update 00-folders.sh
This commit is contained in:
@@ -1,6 +1,14 @@
|
|||||||
#!/usr/bin/with-contenv bashio
|
#!/usr/bin/with-contenv bashio
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
if bashio::config.has_value "PUID" && bashio::config.has_value "PGID"; then
|
||||||
|
PUID="$(bashio::config "PUID")"
|
||||||
|
PGID="$(bashio::config "PGID")"
|
||||||
|
bashio::log.green "Setting user to $PUID:$PGID"
|
||||||
|
id -u photoprism &>/dev/null || usermod -o -u "$PUID" photoprism || true
|
||||||
|
id -g photoprism &>/dev/null || groupmod -o -g "$PGID" photoprism || true
|
||||||
|
fi
|
||||||
|
|
||||||
bashio::log.info "Preparing scripts"
|
bashio::log.info "Preparing scripts"
|
||||||
echo "... creating structure"
|
echo "... creating structure"
|
||||||
mkdir -p \
|
mkdir -p \
|
||||||
|
|||||||
Reference in New Issue
Block a user