macOS: builds from source instead of downloading pre-built binaries; breaks with go.work files
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 55/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Stack tecnológico
- github-actions, go, macos, typescript
- Área
- build-system, ci-cd, devops
Línea de trabajo
Empieza inspeccionando la ruta de macOS de la action, el README y el comportamiento de build_dist.sh de Tailscale. Reproduce el fallo con un archivo go.work del host y compáralo con las rutas de descarga de Linux y Windows. Se considerará terminado cuando se corrija el comportamiento en macOS o se documenten el workaround necesario y su justificación, cubriendo el escenario de workflow indicado.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
The action seems to have two related issues on macOS that are not documented anywhere in the README (at least I haven't found any mentions):
- macOS unconditionally compiles Tailscale from source instead of downloading a pre-built binary.
- The source build breaks when the host repo has a
go.workfile, with no documented workaround.
The workaround I found is setting GOWORK=off for the tailscale step:
- uses: tailscale/github-action@v4
env:
GOWORK: 'off'
AI-generated summary with more details
Problem 1: macOS always builds from source
On Linux and Windows the action downloads pre-built binaries from pkgs.tailscale.com/stable/. On macOS it takes a different path: it clones https://github.com/tailscale/tailscale.git, checks out the requested version tag, and compiles both tailscale and tailscaled by running build_dist.sh.
Pre-built macOS binaries are available on pkgs.tailscale.com/stable/ — the API response includes a MacZips field with links to universal .zip and .pkg files for every stable release. For example, for the default version 1.94.2:
https://pkgs.tailscale.com/stable/Tailscale-1.94.2-macos.zip(25.9 MB)https://pkgs.tailscale.com/stable/Tailscale-1.94.2-macos.pkg(18.3 MB)
The action could download and extract these just as it does for Linux (.tgz) and Windows (.msi).
Impact: Compiling from source requires cloning the entire Tailscale repository and running a full Go build on every CI run that has a cold cache. This is significantly slower than downloading a pre-built binary.
If there is a reason macOS must build from source (e.g. code signing requirements, entitlements, notarization), that reason should be clearly documented in the README.
Problem 2: Source build breaks when the host repo has a go.work file
When the action runs on a macOS runner inside a checked-out repository that contains a go.work file, the source build fails with:
directory cmd/mkversion is contained in a module that is not one of the workspace modules listed in go.work. You can add the module to the workspace using:
go work use .
/path/to/tailscale/build_dist.sh: line 32: VERSION_LONG: unbound variable
What happens: The action clones the Tailscale repository into the runner's working directory (typically a subdirectory of the host repo). When build_dist.sh runs go run ./cmd/mkversion, Go's workspace mode walks up the directory tree, finds the host repo's go.work file, and rejects the build because cmd/mkversion is not listed as a workspace module. Because build_dist.sh runs with set -u, the unbound VERSION_LONG variable then causes a hard abort.
Real-world failure: This broke CI in a consumer repo that uses a go.work file:
https://github.com/trivago/metafold/actions/runs/24346366481/job/71088404471
Workaround: Setting GOWORK=off in the environment before the action runs disables Go workspace mode and unblocks the build:
- uses: tailscale/github-action@v4
env:
GOWORK: 'off'
This workaround is not documented anywhere. The README makes no mention of the always-build-on-macOS behavior or its interaction with Go workspaces.
Requested changes
Either:
(a) Preferred: Download pre-built macOS binaries from pkgs.tailscale.com/stable/ instead of compiling from source, consistent with the Linux and Windows code paths.
(b) Alternative: If compiling from source on macOS is intentional and unavoidable, add the following to the README:
- A note explaining that macOS always compiles Tailscale from source and why.
- A note that the action must be run before checking out any repository that has a
go.workfile, or thatGOWORK=offmust be set in the environment before invoking the action.
Environment:
- Action version:
v4.1.2(SHA306e68a486fd2350f2bfc3b19fcd143891a4a2d8) - Tailscale version:
1.94.2(action default) - Runner:
macos-latest(macOS 15.7.4, ARM64) - Failure trigger: host repo has a
go.workfile at the root
- Lenguaje dominante
- TypeScript
- Estrellas
- 938
- Forks
- 137
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de tailscale/github-action
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
tailscale/github-action#283 · 1 comentario · 1 reacción ·
-
fr
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
tailscale/github-action#317 ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 48/100
tailscale/github-action#316 · 2 comentarios ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 52/100
tailscale/github-action#315 ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 76/100
tailscale/github-action#313 · 1 reacción ·
Todos los issues de tailscale/github-action
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
[Bug]: Matrix progress drafts fail with "Matrix runtime not initialized" during tool activity Abiertobug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
Client support matrix inclusion Abiertoenhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
-
calcite-components needs triage refactor
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
Esri/calcite-design-system#15203 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 90/100
danielmiessler/LifeOS#2218 ·