diff --git a/birdnet-pi/config.json b/birdnet-pi/config.json index cfdf00662..5483d72fc 100644 --- a/birdnet-pi/config.json +++ b/birdnet-pi/config.json @@ -120,6 +120,6 @@ "udev": true, "url": "https://github.com/alexbelgium/hassio-addons/tree/master/birdnet-pi", "usb": true, - "version": "0.13-96", + "version": "0.13-97", "video": true } diff --git a/birdnet-pi/rootfs/etc/cont-init.d/02-restorestreamdata.sh b/birdnet-pi/rootfs/etc/cont-init.d/02-restorestreamdata.sh index e515ae302..18d01dd9c 100755 --- a/birdnet-pi/rootfs/etc/cont-init.d/02-restorestreamdata.sh +++ b/birdnet-pi/rootfs/etc/cont-init.d/02-restorestreamdata.sh @@ -1,5 +1,6 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # shellcheck shell=bash +set -e # Check if there are files in "$HOME"/BirdSongs/StreamData and move them to /data/StreamData if [ -d /data/StreamData ] && [ "$(ls -A /data/StreamData/)" ]; then diff --git a/birdnet-pi/rootfs/etc/cont-init.d/33-mqtt.sh b/birdnet-pi/rootfs/etc/cont-init.d/33-mqtt.sh index 51f4c3c91..f0eb7d401 100755 --- a/birdnet-pi/rootfs/etc/cont-init.d/33-mqtt.sh +++ b/birdnet-pi/rootfs/etc/cont-init.d/33-mqtt.sh @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # shellcheck shell=bash set -e @@ -12,12 +12,12 @@ common_steps () { sed -i "s|%%mqtt_port%%|$MQTT_PORT|g" /helpers/birdnet_to_mqtt.py sed -i "s|%%mqtt_user%%|$MQTT_USER|g" /helpers/birdnet_to_mqtt.py sed -i "s|%%mqtt_pass%%|$MQTT_PASS|g" /helpers/birdnet_to_mqtt.py - + # Copy script to the appropriate directory cp /helpers/birdnet_to_mqtt.py "$HOME"/BirdNET-Pi/scripts/utils/birdnet_to_mqtt.py chown pi:pi "$HOME"/BirdNET-Pi/scripts/utils/birdnet_to_mqtt.py chmod +x "$HOME"/BirdNET-Pi/scripts/utils/birdnet_to_mqtt.py - + # Add hooks to the main analysis script sed -i "/load_global_model, run_analysis/a from utils.birdnet_to_mqtt import automatic_mqtt_publish" "$HOME"/BirdNET-Pi/scripts/birdnet_analysis.py sed -i '/write_to_db(/a\ automatic_mqtt_publish(file, detection, os.path.basename(detection.file_name_extr))' "$HOME"/BirdNET-Pi/scripts/birdnet_analysis.py diff --git a/birdnet-pi/rootfs/etc/cont-init.d/91-nginx_ingress.sh b/birdnet-pi/rootfs/etc/cont-init.d/91-nginx_ingress.sh index 25897d13c..2945c0127 100755 --- a/birdnet-pi/rootfs/etc/cont-init.d/91-nginx_ingress.sh +++ b/birdnet-pi/rootfs/etc/cont-init.d/91-nginx_ingress.sh @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # shellcheck shell=bash set -e diff --git a/birdnet-pi/rootfs/etc/cont-init.d/92-ssl.sh b/birdnet-pi/rootfs/etc/cont-init.d/92-ssl.sh index bfdc593c0..cfda29a43 100755 --- a/birdnet-pi/rootfs/etc/cont-init.d/92-ssl.sh +++ b/birdnet-pi/rootfs/etc/cont-init.d/92-ssl.sh @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # shellcheck shell=bash set -e