Skip to content

fix(packaging): use gateway TOML config in packages#1415

Draft
drew wants to merge 1 commit into
mainfrom
use-toml-in-install
Draft

fix(packaging): use gateway TOML config in packages#1415
drew wants to merge 1 commit into
mainfrom
use-toml-in-install

Conversation

@drew
Copy link
Copy Markdown
Collaborator

@drew drew commented May 15, 2026

Summary

Move Homebrew, deb, and snap gateway package defaults into gateway.toml now that the gateway supports TOML configuration. New installs create the canonical package gateway.toml directly and no longer create a package gateway.env; existing env files are still read so gateway OPENSHELL_* variables continue to take precedence at launch.

Related Issue

N/A

Changes

  • Added a shared package config generator in deploy/common/init-gateway-config.sh for deb, snap, and generated Homebrew formulas.
  • Simplified generation so packages write deterministic canonical TOML instead of interpolating env vars into the config.
  • Avoid selecting a compute driver in generated package TOML; users can select one through --drivers, OPENSHELL_DRIVERS, or edited TOML, otherwise gateway auto-detection applies.
  • Updated Homebrew formula generation to embed the shared helper, create #{var}/openshell/gateway.toml, and keep reading existing gateway.env files before launching.
  • Updated deb packaging to install the shared helper, create %S/openshell/gateway/config.toml, and preserve the systemd EnvironmentFile compatibility path.
  • Updated snap packaging and wrapper to create $SNAP_COMMON/gateway.toml through the shared helper while still honoring launch env such as OPENSHELL_GATEWAY_CONFIG and OPENSHELL_DB_URL.
  • Refreshed package docs/man pages and release formula tests.

Testing

  • mise run pre-commit passes
  • uv run pytest python/openshell/release_formula_test.py
  • sh -n deploy/common/init-gateway-config.sh
  • sh -n deploy/snap/bin/openshell-gateway-wrapper
  • bash -n tasks/scripts/package-deb.sh
  • bash -n tasks/scripts/package-snap.sh
  • generated deb/Homebrew/snap TOML parse smokes
  • systemd-analyze --user verify not run; systemd-analyze is not installed on this host
  • E2E tests added/updated (not applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)

@drew drew requested review from a team, derekwaynecarr, maxamillion and mrunalp as code owners May 15, 2026 22:21
TaylorMutch
TaylorMutch previously approved these changes May 15, 2026
@github-actions
Copy link
Copy Markdown

@drew drew force-pushed the use-toml-in-install branch from f68e3a4 to 0db222c Compare May 15, 2026 22:50
@drew drew marked this pull request as draft May 15, 2026 23:12
@copy-pr-bot
Copy link
Copy Markdown

copy-pr-bot Bot commented May 15, 2026

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@drew drew force-pushed the use-toml-in-install branch 3 times, most recently from a972bad to a5903b7 Compare May 15, 2026 23:36
@drew drew force-pushed the use-toml-in-install branch from a5903b7 to 3d47dc7 Compare May 15, 2026 23:41
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.

2 participants