fix(appimage): bump the Tauri CLI and guard AppDir permissions - #373
Merged
Merged
Conversation
The AppImage catalog rejected 0.0.13 a second time. The `.DirIcon` fix
landed, but the next failure is that `AppRun.wrapped` is packaged
`-rwxrwx---`, so the app cannot start at all when root mounts the image
and another user runs it:
/run/firejail/appimage/AppRun: AppRun.wrapped: Permission denied
That is tauri-apps/tauri#16155: `write_and_make_executable` sets 0o770
on the tools the bundler downloads, and `fs::copy` carries the mode into
<AppDir>/AppRun, which linuxdeploy-plugin-gtk renames to AppRun.wrapped.
It is invisible in normal use because the runtime's FUSE mount reports
the files as owned by whoever launched the image.
Bumps @tauri-apps/cli 2.11.5 -> 2.12.1, which upstream says carries the
fix. Treating that as unverified: the bundler source on `dev` still sets
0o770, so the preview job now asserts the invariant directly — every
AppDir entry world-readable, every owner-executable file
world-executable — rather than trusting the version bump. If 2.12.1 does
not fix it, that check fails and says so instead of shipping another
rejected AppImage.
Only the CLI moves; the `tauri` crate stays on 2.11.1, since the bug is
in the bundler and bumping the runtime risks the overlay regressions
from #196/#226.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Contributor
🔍 Advisory audit reportThese checks don't block merges — they surface drift in dependencies, licensing, and external links. cargo-deny
|
Contributor
📖 Docs preview✅ Built and deployed for commit
Posted by docs-preview.yml — updates in place on every push. |
The AppImage stage stalled with no output for over two hours on three
separate runs today, after building fine on 2026-10-02. It is not the CLI
bump in this branch: a control run on 2.11.5 with only the permissions
guard hung identically.
A probe of the runner image found the cause. `ubuntu22
/ 20260927.309.1` ships fuse3 and libfuse3 but no libfuse2, and
linuxdeploy and its plugins are themselves AppImages that self-mount via
FUSE 2:
$ ./linuxdeploy-x86_64.AppImage --version
dlopen(): error loading libfuse.so.2
$ APPIMAGE_EXTRACT_AND_RUN=1 ./linuxdeploy-x86_64.AppImage --version
linuxdeploy version 1-alpha ...
Neither workflow installed libfuse2 — both relied on the image carrying
it, which it did until this image refresh. Declaring the dependency is
the fix that survives the next refresh; APPIMAGE_EXTRACT_AND_RUN=1 would
also work but changes how every bundled tool runs, to route around a
package we can simply install.
release.yml gets the same line: it bundles the AppImage identically, so a
release tagged today would have hung in build-unix rather than failing.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #373 +/- ##
==========================================
- Coverage 89.72% 89.72% -0.01%
==========================================
Files 148 148
Lines 25671 25671
Branches 861 861
==========================================
- Hits 23034 23033 -1
- Misses 2611 2612 +1
Partials 26 26
🚀 New features to boost your workflow:
|
This reverts commit 3e8509d.
…ters Two defects in the check this branch added. It took three hours to answer. The Linux preview built every bundle, and bundling the rpm from an unstripped DEBUG binary takes 2h44m — measured in run 36894026697, `Bundling ...rpm` at 17:12:39 and the next line at 19:56:42. I read that as a hang and cancelled four runs that were progressing normally. The Linux preview now builds deb + appimage only; rpm is still exercised by release.yml, where the release profile does it in ~27s. It asserted on the wrong thing. `--appimage-extract` does not faithfully reproduce stored directory modes, so the blanket "everything must be world-readable" check reported 143 `drwx------` directories — which the AppImage catalog traverses without complaint, so it is a false positive, and it masked the real result. Modes are now read from the squashfs metadata via `unsquashfs -lls`, and the assertion names the launchers: AppRun and AppRun.wrapped must be world-readable and world-executable, which is exactly the failure that rejected 0.0.13. Anything else that is not world-readable is reported as a warning rather than failing, since there is no evidence it breaks a launch. The run that finally completed (37334101263) answered the original question: `.DirIcon` and the `.desktop` entry both resolve, and no file is owner-executable-only — so @tauri-apps/cli 2.12.1 does fix tauri-apps/tauri#16155, despite `from_mode(0o770)` still being present in the bundler source on `dev`. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
$OLDPWD is only set after a cd, so referencing it outside the extract
subshell tripped `set -u`:
line 57: OLDPWD: unbound variable
The symlink checks had already passed by then, so the failure was mine,
not the bundle's. Resolve the path once, up front.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The AppImage catalog retest on 0.0.13 (appimage.github.io#9123) got past
.DirIcon— that fix did land — and failed on something worse:AppRun.wrappedis packaged-rwxrwx---. This is tauri-apps/tauri#16155:write_and_make_executablesets0o770on every tool the bundler downloads, andfs::copycarries that mode into<AppDir>/AppRun, which linuxdeploy-plugin-gtk renames toAppRun.wrapped.Scope of the bug, stated precisely: launched the normal way this is invisible, because the runtime's FUSE mount reports the files as owned by whoever started the image, so the owner bits apply. It only bites when root mounts the image and a different user runs it —
firejail --appimage, which is exactly how the catalog tests submissions, and some sandboxed launchers. So this is not "the AppImage is broken for everyone"; ordinary double-click and shell launches were fine.What changed
@tauri-apps/cli2.11.5 → 2.12.1. Upstream closed #16155 as completed, and the maintainer's comment says it is "fixed in 2.12 already".Verify AppImage AppDir filesstep now also asserts AppDir permissions.The
tauricrate deliberately stays on 2.11.1 — the bug is in the bundler, which ships with the CLI, and moving the runtime risks the cold-overlay regressions from #196/#226 for no benefit here.Why the version bump alone isn't the whole change
I could not verify upstream's claim, and the source contradicts it. On
devHEAD,crates/tauri-bundler/src/bundle/linux/appimage/mod.rsstill reads:and
linuxdeploy.rsstill does a plainfs::copyofAppRun-<arch>into the AppDir, which preserves the mode. The bundler CHANGELOG has no entry for it either (newest is 2.10.1). So the bump may well not fix it.Rather than cut a release to find out, the preview check now asserts the invariant directly, as a general property instead of against
AppRunby name:That is what
chmod -R a+rX AppDirwould guarantee, and it is what the catalog actually requires. If 2.12.1 does not fix it, this check fails and names the offending paths instead of us shipping a third rejected AppImage.Verification
I ran
audit:workflow-shell(82 steps parse) andactionlint— both clean — plusformat:checkandaudit:spell. The permission assertion itself needs GNUfind -printf, so it cannot run on macOS; it is exercised by adding thebuild:installerslabel to this PR, which builds a real AppImage onubuntu-22.04. I am doing that now and will report what the check says.No tests: this is a toolchain version bump plus a CI assertion, with no application code to exercise.
Next step after this merges
The catalog tests the latest release, so clearing #9123 needs a release built with whatever actually fixes the mode, then
/reteston that PR.🤖 Generated with Claude Code