This commit is contained in:
Alexandre
2023-04-24 13:17:28 +02:00
parent 813e494192
commit 833769cba4
15 changed files with 21 additions and 28 deletions

View File

@@ -48,12 +48,10 @@ if [ -d /var/run/s6/container_environment ]; then
printf "%s" "$LOCATION" > /var/run/s6/container_environment/HOME
printf "%s" "$LOCATION" > /var/run/s6/container_environment/FM_HOME
fi
if [ -f ~/.bashrc ]; then
{
printf "%s" "HOME=\"$LOCATION\""
printf "%s" "FM_HOME=\"$LOCATION\""
} >> ~/.bashrc
fi
usermod --home "$LOCATION" abc

View File

@@ -15,7 +15,7 @@ if bashio::config.has_value 'KEYBOARD'; then
bashio::log.info "Setting keyboard to $KEYBOARD"
sed -i "1a export KEYBOARD=$KEYBOARD" /etc/s6-overlay/s6-rc.d/svc-web/run
if [ -d /var/run/s6/container_environment ]; then printf "%s" "$KEYBOARD" > /var/run/s6/container_environment/KEYBOARD; fi
if [ -f ~/.bashrc ]; then printf "%s" "KEYBOARD=\"$KEYBOARD\"" >> ~/.bashrc; fi
printf "%s" "KEYBOARD=\"$KEYBOARD\"" >> ~/.bashrc
fi || true
# Set cli args
@@ -25,7 +25,7 @@ if bashio::config.has_value 'CLI_ARGS'; then
bashio::log.info "Setting arguments to $CLI_ARGS"
sed -i "1a export CLI_ARGS=$CLI_ARGS" /etc/s6-overlay/s6-rc.d/svc-web/run
if [ -d /var/run/s6/container_environment ]; then printf "%s" "$CLI_ARGS" > /var/run/s6/container_environment/CLI_ARGS; fi
if [ -f ~/.bashrc ]; then printf "%s" "CLI_ARGS=\"$CLI_ARGS\"" >> ~/.bashrc; fi
printf "%s" "CLI_ARGS=\"$CLI_ARGS\"" >> ~/.bashrc
fi || true
# Set password
@@ -35,5 +35,5 @@ if bashio::config.has_value 'PASSWORD'; then
bashio::log.info "Setting password to $PASSWORD"
sed -i "1a export PASSWORD=$PASSWORD" /etc/s6-overlay/s6-rc.d/svc-web/run
if [ -d /var/run/s6/container_environment ]; then printf "%s" "$PASSWORD" > /var/run/s6/container_environment/PASSWORD; fi
if [ -f ~/.bashrc ]; then printf "%s" "PASSWORD=\"$PASSWORD\"" >> ~/.bashrc; fi
printf "%s" "PASSWORD=\"$PASSWORD\"" >> ~/.bashrc
fi || true