Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Site
Clone

Read only, no credentials:

https://rodent.software/vole.git

Write over SSH with a registered key:

git clone ssh://git@rodent.software/vole.git

Self-hosted forge that lives in your Git repo.

#413

Package Windows: an MSI built with wixl, and install.ps1

merged · by keenan 2d ago · merged into main at 31560d91 by keenan 2d ago

keenan opened this 2d ago

The Windows server installs from an MSI now, with install.ps1 on the channel as the one-command path.

Tool change, recorded on the issue. WiX v5/v6 cannot build an MSI outside Windows: relative paths are canonicalized against a hardcoded C:\ and the first Directory is rejected, so the tool cannot run in the release image. Both were tested before switching. The MSI is built by wixl (msitools, the Debian package), which produces a package that installs, upgrades, and uninstalls on the guest. Its 0.101 limits are documented in packaging/windows/vole.wxs: Component/@Permanent and @NeverOverwrite are silently dropped, Environment is unhandled, and Execute="rollback" is emitted as a normal action.

Because the package cannot keep files, the CLI owns them. vole service install now:

  • writes a documented default to %ProgramData%\Vole\vole.toml when given no --config (so the file is not an MSI file and survives uninstall);
  • initializes the instance database and instance repository, as the Linux post-install does, so installing the package leaves a service that can start;
  • registers the service, prepares the access lists, and installs the event-log source, as before.

Upgrade sequencing is explicit. wixl’s MajorUpgrade places RemoveExistingProducts where Windows Installer rejects it (2613), so the upgrade table and sequence are written by hand: old product removal at 1501, stop-and-remove at 3400, install-and-start after InstallFiles. An upgrade therefore stops the service before the running executable would be locked.

A real bug found by installing it. secure.HardenFor accepted a DACL that was a subset of what it was asked to grant: the configuration written by SYSTEM looked valid without the service account’s entry, and the service then failed to read it. HardenFor now requires every requested principal to be present, with a Windows test for the subset case.

Release and verify. Both images gain wixl/msitools; verify builds the MSI and reads its tables back, because wixl exits 0 when a source is missing; the release builds vole-windows-amd64.exe and, for a stable tag, vole-windows-amd64.msi, and attaches install.ps1 beside install.sh. A pre-release tag ships the Windows binary only — ProductVersion cannot carry a pre-release suffix and wixl cannot express the same-version upgrade — and install.ps1 fails with that reason.

Docs: install.md (Windows method), packaging.md (the package, its files, upgrades, and limits), deploy/windows.md (packaged flow, first admin, firewall, upgrades, binary fallback, troubleshooting), RELEASING.md (the Windows sign-off CI cannot do), and the regenerated CLI reference.

Verified on the Server Core 2022 guest: MSI install starts the service and serves HTTP 200 with the documented default config; 0.2.1 upgrades over 0.2.0 with one Programs-and-Features entry; uninstall removes the service and the binary and leaves the configuration, data, and a marker file; install.ps1 installs from a local mirror after checking SHA256SUMS; the cycle repeats cleanly. Windows unit tests pass there; vole workflow run verify passes locally, including the new package step.

Discussion (0)

No discussion yet.