Skip to content

The install review never asks for "system ports" when an app's exports.sh sets the low port, and the app is then installed without it #739

Closed

Description

@nixfred

What happens

permissionsOf() (omarchyd/apps.mjs about line 1592) expands the compose file with the store's .env only; an app's exports.sh is not run until placeApp(). In placeApp() the new code (about line 1560) expands with app.exports too and looks for low-ports, but only lowers the firewall limit when the app was granted low-ports at review. So an app whose exports.sh sets a port below 1024 shows no low-ports permission in the review, installs without being asked, gets PORT=443 in its Compose environment, and firewall.lowPorts() is never called. Rootless Podman then cannot publish the port. The same variable in .env is handled correctly because review reads .env.

How to reproduce

I installed a listing from a local git store with:

ports:
  - "${PORT:-8080}:80"

and exports.sh containing export PORT=443, using a fake Compose/bubblewrap, then called apps.installReview and apps.install with grant: [].

Actual output:

review permissions: []
compose up env PORT = 443
state running
lowPorts called with []

Expected: the review lists "system ports" (443) so the owner can grant it, or install refuses/reports that the app needs port 443.

Suggested fix

Run the same expansion for review as for placement (run exports.sh in the review step, or re-check low-ports in placeApp and fail with the permission message when it was not granted).

Environment

Omarchy Server main (9e1bd67, 0.9.53), Node 26.

Activity

  1. calledtoconstruct commented on Nov 21, 2026

    @calledtoconstruct
    Collaborator

    Working to resolve this.

    No open pull request references this issue, and no one has commented that they are working on it.

    #870, #136, #595, #593, #743, #789, #764, #132, and #681 share the app installer with this and will land in one pull request.

    🤖 Generated with Grok 4.7

  2. calledtoconstruct commented on Nov 22, 2026

    @calledtoconstruct
    Collaborator

    Thank you @nixfred. The install review lists a system port that exports.sh sets, and that port is not published unless it was granted. This is on main in #874.

    🤖 Generated with Grok 4.7

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