fix(ci): reclaim aur-repo ownership after docker chown #49

Merged
razvandimescu merged 1 commits from fix/aur-publish-permission into main 2026-04-09 23:24:30 +08:00
razvandimescu commented 2026-04-09 23:20:36 +08:00 (Migrated from github.com)

Summary

  • Fixes the Push to AUR step in publish-aur.yml failing with error: could not lock config file .git/config: Permission denied (e.g. run 24195384571).
  • Root cause: inside the docker block we chown -R builduser:builduser /pkg, which propagates through the bind mount and transfers ownership of the host's aur-repo/ (including .git/) to the container's builduser UID. When control returns to the runner user, git config user.name can no longer write .git/config and the step exits 255.
  • Fix: sudo chown -R "$(id -u):$(id -g)" . immediately after the docker block, before any host-side git ops.

Test plan

  • Merge to main and confirm the Publish to AUR job reaches git push origin master without a permission error.
  • Confirm .SRCINFO and PKGBUILD land on the AUR repo as expected.

🤖 Generated with Claude Code

## Summary - Fixes the `Push to AUR` step in `publish-aur.yml` failing with `error: could not lock config file .git/config: Permission denied` (e.g. run [24195384571](https://github.com/razvandimescu/numa/actions/runs/24195384571)). - Root cause: inside the docker block we `chown -R builduser:builduser /pkg`, which propagates through the bind mount and transfers ownership of the host's `aur-repo/` (including `.git/`) to the container's builduser UID. When control returns to the runner user, `git config user.name` can no longer write `.git/config` and the step exits 255. - Fix: `sudo chown -R "$(id -u):$(id -g)" .` immediately after the docker block, before any host-side git ops. ## Test plan - [ ] Merge to `main` and confirm the `Publish to AUR` job reaches `git push origin master` without a permission error. - [ ] Confirm `.SRCINFO` and `PKGBUILD` land on the AUR repo as expected. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.