fix(action): rely on runner-provided INPUT_* env vars for docker action - #334
fix(action): rely on runner-provided INPUT_* env vars for docker action#334trcjr wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
This PR improves cross-runner compatibility for the Docker-based GitHub Action by removing an env: block that explicitly mapped inputs.* into INPUT_* variables, and instead relying on the standard runner-provided INPUT_<NAME> environment variables inside the container.
Changes:
- Removed the
runs.envremapping of action inputs toINPUT_*variables inaction.yml. - Ensured the container continues to consume inputs via runner-provided
INPUT_*env vars (as expected for Docker actions).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
hey @trcjr thanks for contribution! tho, this pr is not really correct, for github action inputs from action are passed to docker image via env variables. unfortunately, ci cant run for external contributors, so i created same pr like yours to share ci result: |
b817848 to
529817e
Compare
fix(action): rely on runner-provided INPUT_* env vars for docker action
Summary
Remove the explicit
env:mapping ofINPUT_*variables fromrunsinaction.ymland rely on runner-providedINPUT_<NAME>environment variables inside the container.Problem
Some CI runners (notably Forgejo/Gitea runners) do not expand
${{ inputs.<name> }}inside theenv:block for Docker actions the same way GitHub's runner does. That caused inputs such asINPUT_CONFIGto be the literal${{ inputs.<name> }}inside the container, breaking action behavior on those runners.Solution
Remove the
env:block that re-mapped inputs toINPUT_*inaction.ymland let the runner supply the standardINPUT_<NAME>env vars (the container entrypoint already reads those). This avoids overriding or mismatching runner-supplied values and improves compatibility across runners.Files changed
action.yml(removedenv:block mappingINPUT_*)docker-entrypoint.shTesting performed
make test(integration tests that call the GitHub API were skipped locally by unsettingGITHUB_TOKEN).make check-coverage(passes using.github/.testcoverage-local.yml).make lint(0 issues).How to verify locally
Integration tests that call GitHub's API require a valid
GITHUB_TOKEN; to run checks without those external calls: