diff --git a/pethublocal/rootfs/etc/services.d/pethublocal/run b/pethublocal/rootfs/etc/services.d/pethublocal/run index 83f05e9..57696bd 100755 --- a/pethublocal/rootfs/etc/services.d/pethublocal/run +++ b/pethublocal/rootfs/etc/services.d/pethublocal/run @@ -8,8 +8,15 @@ declare password username="$(bashio::config 'username')" password="$(bashio::config 'password')" -bashio::log.info "Username ${username}" -bashio::log.info "Password ${password}" +if ! bashio::config.has_value "username"; then + bashio::log.warning "Sure Petcare username is not configured" +fi + +if ! bashio::config.has_value "password"; then + bashio::log.warning "Sure Petcare password is not configured" +fi + +bashio::log.info "Starting Pet Hub Local with configured Sure Petcare credentials" cd /share/pethublocal || bashio::exit.nok "Failed to change to Pet Hub Local working directory" -exec pethublocal addon -u "${username}" -p "${password}" \ No newline at end of file +exec pethublocal addon -u "${username}" -p "${password}"