diff --git a/gitea-act-runner/CHANGELOG.md b/gitea-act-runner/CHANGELOG.md index ae4e326..5dd9917 100644 --- a/gitea-act-runner/CHANGELOG.md +++ b/gitea-act-runner/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 1.0.1 - 2026-04-02 + +- fix: act_runner binary path — official image places binary at `/act_runner`, not `/usr/local/bin/act_runner` +- fix: Dockerfile now symlinks `/act_runner` → `/usr/local/bin/act_runner` at build time +- fix: run.sh now auto-detects binary location at runtime as a fallback safety net + ## 1.0.0 - 2026-04-01 - Initial release diff --git a/gitea-act-runner/Dockerfile b/gitea-act-runner/Dockerfile index 1952df4..0e7458a 100644 --- a/gitea-act-runner/Dockerfile +++ b/gitea-act-runner/Dockerfile @@ -1,8 +1,11 @@ ARG BUILD_FROM FROM ${BUILD_FROM} -# Install jq to parse /data/options.json provided by the HA supervisor -RUN apk add --no-cache jq +# Install jq to parse /data/options.json provided by the HA supervisor. +# Also create a stable symlink so act_runner is available at /usr/local/bin/act_runner +# regardless of where the base image places it (official image puts it at /act_runner). +RUN apk add --no-cache jq \ + && ln -sf "$(command -v act_runner 2>/dev/null || echo /act_runner)" /usr/local/bin/act_runner COPY run.sh /run.sh RUN chmod +x /run.sh diff --git a/gitea-act-runner/config.yaml b/gitea-act-runner/config.yaml index 4fbbba1..180cb8d 100644 --- a/gitea-act-runner/config.yaml +++ b/gitea-act-runner/config.yaml @@ -1,5 +1,5 @@ name: Gitea act_runner -version: "1.0.0" +version: "1.0.1" slug: gitea_act_runner description: Run Gitea Actions jobs natively on your Home Assistant machine url: "https://github.com/martemme/HomeAssistantAddons/tree/main/gitea-act-runner" diff --git a/gitea-act-runner/run.sh b/gitea-act-runner/run.sh index eb7ebb9..2535e69 100644 --- a/gitea-act-runner/run.sh +++ b/gitea-act-runner/run.sh @@ -2,9 +2,22 @@ set -e CONFIG="/data/options.json" -ACT_RUNNER="/usr/local/bin/act_runner" -RUNNER_FILE="/data/.runner" ACT_RUNNER_CONFIG="/data/act_runner_config.yaml" +RUNNER_FILE="/data/.runner" + +# Locate the act_runner binary (official image places it at /act_runner, +# Dockerfile symlinks it to /usr/local/bin — accept either). +ACT_RUNNER=$(command -v act_runner 2>/dev/null) +if [[ -z "$ACT_RUNNER" ]]; then + for _candidate in /act_runner /usr/local/bin/act_runner /usr/bin/act_runner; do + if [[ -x "$_candidate" ]]; then ACT_RUNNER="$_candidate"; break; fi + done +fi +if [[ -z "$ACT_RUNNER" ]]; then + echo "[ERROR] act_runner binary not found. Searched: /act_runner, /usr/local/bin/act_runner, /usr/bin/act_runner" + exit 1 +fi +echo "[INFO] Using act_runner at: ${ACT_RUNNER}" echo "[INFO] Reading configuration from ${CONFIG}..."