Files
hassio-addons/cleanuparr/rootfs/ha_entrypoint.sh
alexbelgium a5acad4ca4 fix(pr-2937-review): address reviewer findings on app_config migration
- Remove the orphaned .github/actions/addon-linter composite action: it
  references .github/scripts/prepare_addon_lint_config.py, which was never
  added (the normalization approach was superseded by pinning
  frenck/action-addon-linter directly in #2936). Confirmed unused - no
  workflow invokes it.
- cleanuparr: HA_DATA_DIR pointed at /app_configs/cleanuparr, a path not
  mounted inside the container. cleanuparr's map is app_config:rw, which
  Supervisor mounts at /config, so data was living on the ephemeral
  container filesystem. Point it at /config instead (pre-existing bug,
  not introduced by this PR - just carried the wrong path forward).
- joplin/README.md: joplin's config.yaml still declares config:rw, not
  app_config (it was never part of the 86-manifest migration). Revert the
  doc text that incorrectly started calling it the app_config mapping.
- qbittorrent/00-folders.sh: fix a pre-existing copy/paste bug in the
  migration marker/log for the main-folder migration block - it referenced
  "openvpn" and a "qBitorrent" typo instead of qBittorrent.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-04 19:48:20 +02:00

47 lines
1.9 KiB
Bash
Executable File

#!/bin/bash
# shellcheck shell=bash
set -e
###############################################################################
# Home Assistant Addon entrypoint for Cleanuparr
# The .NET app uses /app/config as its data directory.
# We symlink /app/config → /config (the HA app_config mount, HA persistent storage)
# and start ./Cleanuparr directly, bypassing the original /entrypoint.sh
# which would trigger the /config Docker VOLUME mount.
###############################################################################
# ─── Source standalone bashio if available ───────────────────────────────────
if [ -f /usr/local/lib/bashio-standalone.sh ]; then
# shellcheck disable=SC1091
source /usr/local/lib/bashio-standalone.sh
fi
# ─── Run cont-init.d scripts (banner, custom_script, ...) ────────────────────
if [ -d /etc/cont-init.d ]; then
for script in /etc/cont-init.d/*.sh; do
[ -f "$script" ] || continue
echo "[Cleanuparr] Running init script: $script"
bash "$script"
done
fi
# ─── Setup persistent data directory ─────────────────────────────────────────
HA_DATA_DIR="/config"
echo "[Cleanuparr] Setting up data directory: $HA_DATA_DIR"
mkdir -p "$HA_DATA_DIR"
# Symlink /app/config → HA persistent storage
# The .NET app uses /app/config, NOT /config at the filesystem root
if [ -d /app/config ] && [ ! -L /app/config ]; then
cp -rn /app/config/. "$HA_DATA_DIR/" 2>/dev/null || true
rm -rf /app/config
fi
ln -sfn "$HA_DATA_DIR" /app/config
chown -R "${PUID:-0}:${PGID:-0}" "$HA_DATA_DIR"
# ─── Start Cleanuparr directly (bypass original /entrypoint.sh) ──────────────
echo "[Cleanuparr] Starting application on port ${HTTP_PORTS:-11011}..."
cd /app
exec ./Cleanuparr