Classic confinement request for pkgtui

Reasoning:

pkgtui is an interactive frontend to the package managers installed on the host. Its core functionality requires executing the host’s package-manager commands and managing packages on the host filesystem, rather than packages within the snap runtime.

For example, the apt backend invokes apt-cache, apt-get, dpkg and apt-mark. The snap and flatpak backends similarly invoke the host’s snap and flatpak commands.

Privileged apt and snap operations invoke host sudo when the user is not already root. Commands run in an embedded pseudo-terminal so that authentication prompts and interactive package-manager dialogs work. Package-changing actions require explicit confirmation in the UI. The application is not a background management daemon.

I understand that strict confinement is generally preferred over classic. I also understand that the documented unsupported categories include management snaps, third-party installers and direct sudo access, which appear relevant to this application.

I have not yet validated a strict-confinement implementation, and do not want to claim that interfaces have been tested when they have not. Could the reviewers advise whether classic confinement can be considered for this use case, or what supported architecture would be required?

The initial upload targeting edge was blocked with: “confinement ‘classic’ not allowed”.

This request has been added to the queue for review by the @reviewers team.

Not a store reviewer, however, I would suggest AVOID investing effort in snap packaging without prior agreement from the snapd architects if your application is in the unsupported categories in the first place, as this would unnecessarily increase the workload of the store reviewers, leading to longer response time for other applicants that indeed have a elligible use case.

IIRC, store reviewers has no say on the change of classic confinement supported categories, only snapd architects are qualified for such decision.

File a forum topic in the snapd forum category regarding your usecase first. You can also search for similar applications from former requests.

AFAICT, currently the only way to distribute this snap in classic confinement is via non-store channels like GitHub Releases. As there’re no automatic upgrade mechanism in this case is you should implement update checking logic within the application and request the user to install updates manually by download the package and install it via the snap install --dangerous command.

My 2 cents.

2 Likes

Hello @senseipado :slight_smile:

Unfortunately, as you suspected, this use case falls squarely into several of the documented unsupported categories for classic confinement (see Process for reviewing classic confinement snaps):

  • Management snaps: pkgtui's core purpose is managing packages on the host system.

  • 3rd-party installer snaps: installing/removing native packages (apt/dpkg), snaps, and flatpaks is exactly the “installer for native packages, appimages, flatpaks, snaps” case.

  • Direct access to sudo: invoking the host’s sudo for privileged apt/snap operations is explicitly listed as unsupported

Given all these pkgtui is not a good candidate for classic confinement. For this kind of tool, we recommend continuing to use native package management tools (apt, snap, flatpak directly) rather than distributing the snap through the store.

Thank you @Lin-Buo-Ren for the insights and the correct guidance :heart:

1 Like