mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-01-10 18:01:03 +01:00
fix(birdnet-pi): honor standalone pi password
This commit is contained in:
@@ -21,9 +21,17 @@ fi
|
||||
# Set password
|
||||
bashio::log.info "Setting password for the user pi"
|
||||
if bashio::config.has_value "pi_password"; then
|
||||
echo "pi:$(bashio::config "pi_password")" | chpasswd
|
||||
PI_PASSWORD="$(bashio::config "pi_password")"
|
||||
elif [[ -n "${pi_password:-}" ]]; then
|
||||
PI_PASSWORD="${pi_password}"
|
||||
fi
|
||||
|
||||
if [[ -n "${PI_PASSWORD:-}" ]]; then
|
||||
echo "pi:${PI_PASSWORD}" | chpasswd
|
||||
bashio::log.info "Password set successfully for user pi."
|
||||
else
|
||||
bashio::log.info "No password specified for user pi. Keeping existing password."
|
||||
fi
|
||||
bashio::log.info "Password set successfully for user pi."
|
||||
|
||||
# Use timezone defined in add-on options if available
|
||||
bashio::log.info "Setting timezone :"
|
||||
|
||||
Reference in New Issue
Block a user