mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-30 20:34:04 +02:00
Compare commits
7 Commits
dda7258567
...
b49d5e9b62
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b49d5e9b62 | ||
|
|
1f1c5aa06f | ||
|
|
3ce74a2e0f | ||
|
|
b740741dbf | ||
|
|
f4ee102ae6 | ||
|
|
742e2ce52e | ||
|
|
fae90f0614 |
@@ -1,4 +1,8 @@
|
||||
|
||||
## 0.5.6-2 (2026-03-11)
|
||||
- Add container timezone management: TZ option now properly configures the container timezone (symlinks /etc/localtime, writes /etc/timezone, exports to s6 environment)
|
||||
- Change default timezone from Etc/UTC to Europe/Paris
|
||||
|
||||
## 0.5.6 (2026-03-07)
|
||||
- Update to latest version from Suncuss/BirdNET-PiPy (changelog : https://github.com/Suncuss/BirdNET-PiPy/releases)
|
||||
## 0.5.5-2 (04-03-2026)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
## Options
|
||||
|
||||
```yaml
|
||||
TZ: Etc/UTC # Timezone, see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List
|
||||
TZ: Europe/Paris # Timezone, see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List
|
||||
ICECAST_PASSWORD: "" # Optional: set a persistent password for the audio stream
|
||||
STREAM_BITRATE: 320k # Bitrate for the mp3 stream
|
||||
RECORDING_MODE: rtsp # pulseaudio | http_stream | rtsp
|
||||
|
||||
@@ -116,6 +116,8 @@ RUN chmod 777 /ha_entrypoint.sh
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh"
|
||||
RUN chmod 0755 /usr/local/lib/bashio-standalone.sh
|
||||
|
||||
USER root
|
||||
|
||||
############
|
||||
# 5 Labels #
|
||||
############
|
||||
|
||||
@@ -73,7 +73,7 @@ name: BirdNET-PiPy
|
||||
options:
|
||||
env_vars: []
|
||||
ICECAST_PASSWORD: ''
|
||||
TZ: Etc/UTC
|
||||
TZ: Europe/Paris
|
||||
data_location: /config/data
|
||||
panel_icon: mdi:bird
|
||||
ports:
|
||||
@@ -97,5 +97,5 @@ schema:
|
||||
ssl: bool?
|
||||
slug: birdnet-pipy
|
||||
url: https://github.com/alexbelgium/hassio-addons/tree/master/birdnet-pipy
|
||||
version: "0.5.6"
|
||||
version: "0.5.6-3"
|
||||
webui: "[PROTO:ssl]://[HOST]:[PORT:80]"
|
||||
|
||||
27
birdnet-pipy/rootfs/etc/cont-init.d/02-timezone.sh
Executable file
27
birdnet-pipy/rootfs/etc/cont-init.d/02-timezone.sh
Executable file
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -euo pipefail
|
||||
|
||||
# Use timezone defined in add-on options
|
||||
bashio::log.info "Setting timezone..."
|
||||
TZ_VALUE="$(bashio::config 'TZ' || true)"
|
||||
TZ_VALUE="${TZ_VALUE:-Europe/Paris}"
|
||||
|
||||
if [ ! -f "/usr/share/zoneinfo/${TZ_VALUE}" ]; then
|
||||
bashio::log.warning "Invalid timezone '${TZ_VALUE}'. Falling back to Europe/Paris."
|
||||
bashio::log.warning "See https://en.wikipedia.org/wiki/List_of_tz_database_time_zones for valid values."
|
||||
TZ_VALUE="Europe/Paris"
|
||||
fi
|
||||
|
||||
# Apply timezone to the container
|
||||
ln -sf "/usr/share/zoneinfo/${TZ_VALUE}" /etc/localtime
|
||||
echo "${TZ_VALUE}" > /etc/timezone
|
||||
export TZ="${TZ_VALUE}"
|
||||
sed -i "1a TZ=\"${TZ_VALUE}\"" /etc/services.d/*
|
||||
|
||||
# Update s6 container environment so child processes inherit the timezone
|
||||
if [ -d /var/run/s6/container_environment ]; then
|
||||
echo "${TZ_VALUE}" > /var/run/s6/container_environment/TZ
|
||||
fi
|
||||
|
||||
bashio::log.notice "Timezone set to: ${TZ_VALUE}"
|
||||
Reference in New Issue
Block a user