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.
Package Windows: an MSI built with wixl, and install.ps1
31560d91c4e27f3fdee2652aa3b4b12b8343903d · Keenan Nemetz · 2d ago · parent 9cbfa891
Package Windows: an MSI built with wixl, and install.ps1 The Windows server installs from an MSI now, with install.ps1 on the channel as the one-command path, the same shape as the Linux installer. The MSI is built by wixl (msitools), not the WiX toolset. WiX v5 and v6 refuse to build outside Windows: every relative path is canonicalized against a hardcoded C:\ and the first Directory is rejected, so it cannot run in the release image. I tested both before choosing; wixl 0.101 is what Debian bookworm ships and it produces a package that installs, upgrades, and uninstalls on the Server Core guest. Its limits shaped the design and are recorded in the .wxs header: it silently drops Component/@Permanent and @NeverOverwrite, cannot edit PATH, and cannot schedule rollback actions, so the configuration and the data directory belong to `vole service install` and not to the package. That moved two things into the CLI. `service install` now writes a documented default configuration to %ProgramData%\Vole\vole.toml when it is given none, and initializes the instance database and repository like the Linux post-install step, so the package's only action is the binary registering itself. The same command serves a hand install and a pre-release, which has no MSI. The MSI's upgrade table is written by hand because wixl's MajorUpgrade schedules RemoveExistingProducts in the window Windows Installer rejects (error 2613). RemoveExistingProducts is placed at 1501, the service's stop-and-remove at 3400, and install-and-start after InstallFiles, so an upgrade removes the old product before the new files land and the running executable is never locked. Fixed along the way, found by installing the MSI: secure.HardenFor accepted an access list that was a subset of what it was asked to grant, so a configuration written by SYSTEM looked correct and never got the service account's entry; the service then could not read it and failed to start. HardenFor now requires every requested principal to be present, with a Windows test for the subset case. Release and verify wiring: both images gain wixl and msitools, verify builds the MSI and reads its tables back (wixl exits 0 when a source is missing), and the release builds the Windows binary and, for a stable tag, the MSI, and publishes install.ps1 beside install.sh. A pre-release tag has no MSI: ProductVersion cannot carry a pre-release suffix and wixl cannot express the same-version upgrade, so those releases ship the binary and install.ps1 says so. Docs: install.md gains the Windows method, packaging.md the Windows package and its limits, deploying windows.md the packaged flow (install, configure, first admin, firewall, upgrade, binary fallback, troubleshooting), and RELEASING.md the Windows sign-off a Linux runner cannot perform. Verified on the Server Core 2022 guest: MSI install starts the service and serves HTTP 200, with the config created at the documented default and the data kept; 0.2.1 upgrades over 0.2.0 with one Programs-and-Features entry and the service running; uninstall removes the service and the binary and leaves the config, data, and a marker file; install.ps1 installs from a local mirror after checking SHA256SUMS; reinstall and uninstall are repeatable. Windows unit tests pass there, and `vole workflow run verify` passes locally including the new package step. Part of 01M8SE6GWX1DGYPY6H9YC142C2.
.vole/images/release.yaml +1−1
| @@ -21,7 +21,7 @@ env: | |||
| 21 | 21 | GOMODCACHE: "/cache/go-mod" | |
| 22 | 22 | GOCACHE: "/cache/go-build" | |
| 23 | 23 | run: | |
| 24 | - apt-get update && apt-get install -y --no-install-recommends git ca-certificates python3 dpkg-dev createrepo-c pacman-package-manager makepkg libarchive-tools zstd rpm-common rpm gnupg && rm -rf /var/lib/apt/lists/* | ||
| 24 | - apt-get update && apt-get install -y --no-install-recommends git ca-certificates python3 dpkg-dev createrepo-c pacman-package-manager makepkg libarchive-tools zstd rpm-common rpm gnupg wixl msitools && rm -rf /var/lib/apt/lists/* | ||
| 25 | 25 | # The test step spawns ssh and ssh-keygen, which call getpwuid() and exit 255 | |
| 26 | 26 | # with "No user exists for uid N" when the container runs as the host's uid and | |
| 27 | 27 | # the image has no passwd entry for it. Same reason, same entry as the verify | |