Skip to content

Support company HTTP proxies in menubar installer downloads #473

@sleicht

Description

@sleicht

Problem

codeburn menubar installs the macOS menubar app by downloading release metadata, the app zip, and checksum from GitHub. In company networks, direct outbound GitHub access may be blocked and traffic must go through an HTTP proxy.

Current installer network calls do not respect proxy environment variables, so install/update can fail behind corporate proxies.

Relevant calls:

  • release lookup: src/menubar-installer.ts:133-144
  • checksum download: src/menubar-installer.ts:147-155
  • app zip download: src/menubar-installer.ts:169-180

Proposed change

Add proxy-aware fetch support for the menubar installer:

  • honour HTTPS_PROXY / https_proxy for HTTPS requests
  • fall back to HTTP_PROXY / http_proxy
  • honour NO_PROXY / no_proxy for host/domain bypass
  • route installer GitHub API, checksum, and zip downloads through that proxy
  • add tests for proxy selection and NO_PROXY bypass

Implementation notes

Current local change uses undici ProxyAgent because Node does not provide a built-in node:http.ProxyAgent.

Touched areas:

  • proxy resolution and fetch wrapper: src/menubar-installer.ts:35-61
  • proxy-aware installer calls: src/menubar-installer.ts:133-173
  • tests: tests/menubar-installer.test.ts:101-116
  • dependency: package.json:49-57

Acceptance criteria

  • codeburn menubar works when HTTPS_PROXY=http://company-proxy:port is set.
  • NO_PROXY=.github.com bypasses proxy for GitHub hosts.
  • Existing menubar installer behaviour remains unchanged when no proxy env vars are set.
  • Targeted installer tests pass.
  • TypeScript compile passes.

Verification from local change

  • npm test -- run tests/menubar-installer.test.ts passed: 9 tests.
  • npx tsc --noEmit passed.
  • npm run build was blocked by unrelated network failure in scripts/bundle-litellm.mjs before compilation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions