Skip to content

fix: add chown and chmod helpers - #22

Draft
neurekadev wants to merge 1 commit into
getarcaneapp:mainfrom
neurekadev:fix/4885-chown-chmod-applets
Draft

neurekadev wants to merge 1 commit into
getarcaneapp:mainfrom
neurekadev:fix/4885-chown-chmod-applets

Conversation

@neurekadev

Copy link
Copy Markdown

Important

Merge order: getarcaneapp/arcane#4887 first, then this. On its own, this would let Arcane's restore step run, but that step currently copies the wrong owner and mode (root:root 0777). getarcaneapp/arcane#4887 makes it take them from the archive.

Closes getarcaneapp/arcane#4885 together with getarcaneapp/arcane#4887.

What

Adds the BusyBox chown and chmod applets (CONFIG_CHOWN, CONFIG_CHMOD, plus their /bin links) and lists them in the README.

Why

When Arcane restores an uploaded volume archive into a newly created Compose volume (project copy/move with volumes, released in 3.1.0), it sets the volume root's owner and mode with chown/chmod in this helper image. Neither applet was built in, so every such restore failed with sh: line 0: chown: not found.

Testing

  • just build --platform linux/amd64 and just test ghcr.io/getarcaneapp/tools:dev: all validation checks passed, including "no extra helper commands slipped into the runtime image".
  • Arcane's restore commands against the built image:
$ docker run --rm -v vol:/volume ghcr.io/getarcaneapp/tools:dev sh -c '... chown 999:999 tmp && chmod 700 tmp && chown "$(stat -c %u:%g tmp)" /volume && chmod "$(stat -c %a tmp)" /volume && stat -c "%u:%g %a" /volume'
999:999 700

AI disclosure

Claude Code (Claude Opus 5.5) investigated this, made the change and drafted this description, at my direction.

🤖 Generated with Claude Code

Arcane restores an uploaded volume archive into a newly created Compose
volume by copying the archive root's owner and mode onto the volume
root with chown and chmod. The image had neither applet, so project
copy/move with volumes failed with "chown: not found".

Refs getarcaneapp/arcane#4885

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@neurekadev

Copy link
Copy Markdown
Author

🔍 Code Review

PR #22 · ada7212..354a2ef · 2 files · ✅ No findings

Critical: 0 High: 0 Medium: 0 Low: 0 Informational: 0

🤖 Claude Opus 5.5 (High) · T3 Code (Claude Code) · Round 1 of 3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🐞 Bug: Project copy/move with volumes fails: chown not found in the tools helper image

1 participant