Skip to content

Linux: container builds leave dist/ (and scaffolded crates) owned by root, breaking plugin loading in the editor #2

Description

@lucasmundim

Summary

On Linux hosts, every renzora command that writes to the checkout through the /app/src bind mount (build, run, upx, add, remove) leaves the written files owned by root:root, because the toolchain containers run as root and no ownership fixup is done afterwards.

Impact

The most visible consequence is that renzora run produces an editor with no working plugins. The engine editor's plugin loader stages a shadow copy of each plugin into plugins/.reload/ before loading it (required for hot-reload), and it cannot create that directory inside a root-owned dist/:

ERROR renzora_plugin::host::loader: [plugin] liblua.so failed: could not stage a copy to load: Permission denied (os error 13)
ERROR renzora_plugin::host::loader: [plugin] libaudio.so failed: could not stage a copy to load: Permission denied (os error 13)
... (repeated for all 67 plugins)

The editor then boots without Lua scripting, audio, and all post-process effects — which is easy to misread as an engine bug rather than a permissions problem.

Additionally, a root-owned dist/ (or a crate scaffolded by renzora add) cannot be modified or deleted by the user without sudo.

Reproduction

On a Linux host:

  1. renzora init
  2. renzora run
  3. ls -l dist/linux-x64/ → everything is root:root; the editor log shows the Permission denied (os error 13) plugin errors above.

Workaround

sudo chown -R $(id -u):$(id -g) dist/ after each container build.

Fix

#1 fixes this by chowning the written paths back to the checkout's owner from inside the container after each bind-mount-writing command. See the PR description for why docker create --user was not used instead.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions