Skip to content

pc-agents follow-ups from #286: prerelease version check, install order, apt noninteractive, desk memory cap #296

Closed

Description

@scuttletoby

Follow-ups from the two lenses on #286 (security and state, both SAFE at 8baa05e). None blocks; fix together in one small PR.

pc-agents setup

  1. Some 0.1.7 prereleases pass the minimum-version check without the managed policy (lib/pc_agents.py:47-49, :82): 0.1.7-nightly.20261031.3991, .4004, .20261101.4016, .4035 were built before it. Rank a prerelease below its release.
  2. Packages are installed before setup writes its own /etc/resolv.conf (sbin/pc-agents:238 vs :245): with nameservers that broke DNS under an older kit, the corrected machine file never takes effect because apt-get update fails first. Install after the file writes and before the firewall loads.
  3. dpkg and apt-get run without DEBIAN_FRONTEND=noninteractive and a config-file option (:205-207); a config-file question or a held dpkg lock fails, and the advice printed then fails too.
  4. A package on hold counts as missing, so every setup run calls apt (nit).

Desk (start-desk.ps1)
5. A kept memory value WSL rejects (memory=26 GB with a space, maybe 30720mb in lower case) is kept; WSL then falls back to 50% of RAM while the script says "no change" (:167, :174). Normalise the value WSL reads, or rewrite it. Needs a check on a real desk for the case question.
6. -MemoryGB can no longer lower the cap, and a kept cap has no upper bound (:172-175, :193): 64GB on a 32 GB PC is kept, which gets around the "Windows keeps 2 GB" refusal. Keep a higher value only when -MemoryGB was not given, and only up to RAM less 2 GB.

Tests
7. Version compared as a string, or >= changed to >, stays green: add 0.1.7 and 0.1.10 as accepted versions.
8. dpkg moved after apt-get install stays green: make the fake apt-get refuse while a package is unpacked.

Docs
9. README step 8: a git name with an apostrophe fails (the rest of the wsl line goes through root's shell). The PR body's "the 2-minute check stops an old T3" holds only once the new kit is installed.

General vs project: all general (fork-kit/pc-agents).

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