mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-04-05 21:56:27 +02:00
Fix Redis in immich_cuda: install redis-server directly instead of Docker mods
Apply the same Redis fix from the immich addon to immich_cuda: - Remove DOCKER_MODS env var from Dockerfile and config.yaml - Add redis-server to PACKAGES for direct installation - s6-rc service files, redis.conf, and 20-folders.sh were already updated This prevents ECONNRESET errors caused by Docker mods failing to install Redis at runtime (issue #2615). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
|
||||
## 2.6.2-2 (2026-03-28)
|
||||
- Fix Redis startup: install redis-server directly instead of via Docker mods to prevent ECONNRESET errors (issue #2615)
|
||||
|
||||
## 2.6.2 (2026-03-28)
|
||||
- Update to latest version from imagegenius/docker-immich (changelog : https://github.com/imagegenius/docker-immich/releases)
|
||||
|
||||
|
||||
@@ -34,13 +34,8 @@ COPY ha_lsio.sh /ha_lsio.sh
|
||||
ARG CONFIGLOCATION="/config"
|
||||
RUN chmod 744 /ha_lsio.sh && if grep -qr "lsio" /etc; then /ha_lsio.sh "$CONFIGLOCATION"; fi && rm /ha_lsio.sh
|
||||
|
||||
# Install REDIS
|
||||
ENV DOCKER_MODS="imagegenius/mods:universal-redis"
|
||||
|
||||
# && chmod 777 -R /docker-mods \
|
||||
# && /./docker-mods/* || ls / \
|
||||
# && if [ !-f /defaults/redis.conf ]; then echo "Not installed" && exit 1; fi
|
||||
#ENV DOCKER_MODS=""
|
||||
# Install REDIS directly instead of via Docker mods for reliability
|
||||
# (Docker mods can fail to install Redis at runtime, causing ECONNRESET errors)
|
||||
|
||||
##################
|
||||
# 3 Install apps #
|
||||
@@ -63,7 +58,7 @@ COPY ha_automodules.sh /ha_automodules.sh
|
||||
RUN chmod 744 /ha_automodules.sh && /ha_automodules.sh "$MODULES" && rm /ha_automodules.sh
|
||||
|
||||
# Manual apps
|
||||
ENV PACKAGES="sudo yamllint pip sed jq"
|
||||
ENV PACKAGES="sudo yamllint pip sed jq redis-server"
|
||||
|
||||
# Automatic apps & bashio
|
||||
COPY ha_autoapps.sh /ha_autoapps.sh
|
||||
|
||||
@@ -71,7 +71,6 @@ devices:
|
||||
- /dev/nvme2
|
||||
environment:
|
||||
CI_PORT: "8080"
|
||||
DOCKER_MODS: imagegenius/mods:universal-redis
|
||||
MACHINE_LEARNING_CACHE_FOLDER: /data/machine-learning
|
||||
MACHINE_LEARNING_WORKERS: "1"
|
||||
MACHINE_LEARNING_WORKER_TIMEOUT: "120"
|
||||
@@ -143,6 +142,6 @@ slug: immich
|
||||
udev: true
|
||||
url: https://github.com/alexbelgium/hassio-addons
|
||||
usb: true
|
||||
version: "2.6.2"
|
||||
version: "2.6.2-2"
|
||||
video: true
|
||||
webui: http://[HOST]:[PORT:8080]
|
||||
|
||||
64
immich/rootfs/defaults/redis.conf
Normal file
64
immich/rootfs/defaults/redis.conf
Normal file
@@ -0,0 +1,64 @@
|
||||
## custom configuration file, please be aware that changing options here may break things
|
||||
## uncomment what you need to adjust, leave commented to use default settings
|
||||
## see https://redis.io/topics/config for help
|
||||
|
||||
#protected-mode yes
|
||||
#tcp-backlog 511
|
||||
#timeout 0
|
||||
#tcp-keepalive 300
|
||||
#databases 16
|
||||
#save 900 1
|
||||
#save 300 10
|
||||
#save 60 10000
|
||||
#stop-writes-on-bgsave-error yes
|
||||
#rdbcompression yes
|
||||
#rdbchecksum yes
|
||||
#dbfilename dump.rdb
|
||||
#rdb-del-sync-files no
|
||||
#replica-serve-stale-data yes
|
||||
#replica-read-only yes
|
||||
#repl-diskless-sync no
|
||||
#repl-diskless-sync-delay 5
|
||||
#repl-diskless-load disabled
|
||||
#repl-disable-tcp-nodelay no
|
||||
#replica-priority 100
|
||||
#acllog-max-len 128
|
||||
#lazyfree-lazy-eviction no
|
||||
#lazyfree-lazy-expire no
|
||||
#lazyfree-lazy-server-del no
|
||||
#replica-lazy-flush no
|
||||
#lazyfree-lazy-user-del no
|
||||
#oom-score-adj no
|
||||
#oom-score-adj-values 0 200 800
|
||||
#appendonly no
|
||||
#appendfilename "appendonly.aof"
|
||||
#appendfsync everysec
|
||||
#no-appendfsync-on-rewrite no
|
||||
#auto-aof-rewrite-percentage 100
|
||||
#auto-aof-rewrite-min-size 64mb
|
||||
#aof-load-truncated yes
|
||||
#aof-use-rdb-preamble yes
|
||||
#lua-time-limit 5000
|
||||
#slowlog-log-slower-than 10000
|
||||
#slowlog-max-len 128
|
||||
#latency-monitor-threshold 0
|
||||
#notify-keyspace-events ""
|
||||
#hash-max-ziplist-entries 512
|
||||
#hash-max-ziplist-value 64
|
||||
#list-max-ziplist-size -2
|
||||
#list-compress-depth 0
|
||||
#set-max-intset-entries 512
|
||||
#zset-max-ziplist-entries 128
|
||||
#zset-max-ziplist-value 64
|
||||
#hll-sparse-max-bytes 3000
|
||||
#stream-node-max-bytes 4096
|
||||
#stream-node-max-entries 100
|
||||
#activerehashing yes
|
||||
#client-output-buffer-limit normal 0 0 0
|
||||
#client-output-buffer-limit replica 256mb 64mb 60
|
||||
#client-output-buffer-limit pubsub 32mb 8mb 60
|
||||
#hz 10
|
||||
#dynamic-hz yes
|
||||
#aof-rewrite-incremental-fsync yes
|
||||
#rdb-save-incremental-fsync yes
|
||||
#jemalloc-bg-thread yes
|
||||
@@ -97,9 +97,8 @@ fi
|
||||
# REDIS LOCATION #
|
||||
##################
|
||||
|
||||
echo "sed -i \"s=/config/redis=/data/redis=g\" /etc/s6*/s6*/*/run" >> /docker-mods
|
||||
echo "sed -i \"s=/config/log/redis=/data/log=g\" /etc/s6*/s6*/*/run" >> /docker-mods
|
||||
mkdir -p /data/redis
|
||||
mkdir -p /data/log
|
||||
mkdir -p /var/run/redis
|
||||
chmod 755 /data/redis
|
||||
chmod 755 /data/log
|
||||
|
||||
27
immich/rootfs/etc/s6-overlay/s6-rc.d/svc-redis/run
Normal file
27
immich/rootfs/etc/s6-overlay/s6-rc.d/svc-redis/run
Normal file
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
# Create Redis directories
|
||||
mkdir -p \
|
||||
/data/redis \
|
||||
/data/log \
|
||||
/var/run/redis
|
||||
|
||||
# Copy default redis.conf if not present
|
||||
if [[ ! -f /data/redis/redis.conf ]]; then
|
||||
cp /defaults/redis.conf /data/redis/redis.conf 2>/dev/null || touch /data/redis/redis.conf
|
||||
fi
|
||||
|
||||
# Set permissions
|
||||
chown -R root:root \
|
||||
/data/redis \
|
||||
/data/log \
|
||||
/var/run/redis
|
||||
|
||||
exec \
|
||||
redis-server /data/redis/redis.conf \
|
||||
--bind 127.0.0.1 \
|
||||
--port 6379 \
|
||||
--pidfile /var/run/redis/redis.pid \
|
||||
--always-show-logo no \
|
||||
--dir /data/redis \
|
||||
--logfile /data/log/redis.log
|
||||
1
immich/rootfs/etc/s6-overlay/s6-rc.d/svc-redis/type
Normal file
1
immich/rootfs/etc/s6-overlay/s6-rc.d/svc-redis/type
Normal file
@@ -0,0 +1 @@
|
||||
longrun
|
||||
@@ -1,4 +1,7 @@
|
||||
|
||||
## 2.6.2-2 (2026-03-28)
|
||||
- Fix Redis startup: install redis-server directly instead of via Docker mods to prevent ECONNRESET errors (issue #2615)
|
||||
|
||||
## 2.6.2 (2026-03-28)
|
||||
- Update to latest version from imagegenius/docker-immich (changelog : https://github.com/imagegenius/docker-immich/releases)
|
||||
|
||||
|
||||
@@ -34,13 +34,8 @@ COPY ha_lsio.sh /ha_lsio.sh
|
||||
ARG CONFIGLOCATION="/config"
|
||||
RUN chmod 744 /ha_lsio.sh && if grep -qr "lsio" /etc; then /ha_lsio.sh "$CONFIGLOCATION"; fi && rm /ha_lsio.sh
|
||||
|
||||
# Install REDIS
|
||||
ENV DOCKER_MODS="imagegenius/mods:universal-redis"
|
||||
|
||||
# && chmod 777 -R /docker-mods \
|
||||
# && /./docker-mods/* || ls / \
|
||||
# && if [ !-f /defaults/redis.conf ]; then echo "Not installed" && exit 1; fi
|
||||
#ENV DOCKER_MODS=""
|
||||
# Install REDIS directly instead of via Docker mods for reliability
|
||||
# (Docker mods can fail to install Redis at runtime, causing ECONNRESET errors)
|
||||
|
||||
##################
|
||||
# 3 Install apps #
|
||||
@@ -63,7 +58,7 @@ COPY ha_automodules.sh /ha_automodules.sh
|
||||
RUN chmod 744 /ha_automodules.sh && /ha_automodules.sh "$MODULES" && rm /ha_automodules.sh
|
||||
|
||||
# Manual apps
|
||||
ENV PACKAGES="sudo sed yamllint pip jq"
|
||||
ENV PACKAGES="sudo sed yamllint pip jq redis-server"
|
||||
|
||||
# Automatic apps & bashio
|
||||
COPY ha_autoapps.sh /ha_autoapps.sh
|
||||
|
||||
@@ -69,7 +69,6 @@ devices:
|
||||
- /dev/nvme2
|
||||
environment:
|
||||
CI_PORT: "8080"
|
||||
DOCKER_MODS: imagegenius/mods:universal-redis
|
||||
MACHINE_LEARNING_CACHE_FOLDER: /data/machine-learning
|
||||
MACHINE_LEARNING_WORKERS: "1"
|
||||
MACHINE_LEARNING_WORKER_TIMEOUT: "120"
|
||||
@@ -141,6 +140,6 @@ slug: immich_cuda
|
||||
udev: true
|
||||
url: https://github.com/alexbelgium/hassio-addons
|
||||
usb: true
|
||||
version: "2.6.2"
|
||||
version: "2.6.2-2"
|
||||
video: true
|
||||
webui: http://[HOST]:[PORT:8080]
|
||||
|
||||
Reference in New Issue
Block a user