Etapa G (go): triage cola envenenada del VPS — purga 25 (misimports/CGO/embed) + 10 fixes (subdir dolt-atlas-omp, crane ./cmd/crane, trivy GOEXPERIMENT=jsonv2, xq/tea/staticcheck/syft/apko a vía Go auto)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -16,27 +16,6 @@ target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
|
||||
[build.phases]
|
||||
# de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático):
|
||||
compile = '''
|
||||
_abuild_phase() {
|
||||
mkdir build
|
||||
go build -o build/ -tags -tags=pivkey,pkcs11key "$builddir"/...
|
||||
|
||||
for i in bash fish zsh; do
|
||||
"$builddir"/build/apko completion $i > "$builddir"/apko.$i
|
||||
done
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
# de package() de Alpine (traducido $pkgdir→/out):
|
||||
install = '''
|
||||
_abuild_phase() {
|
||||
install -Dm755 "$builddir"/build/apko "/out"/usr/bin/apko
|
||||
|
||||
install -Dm644 "$builddir"/apko.bash "/out"/usr/share/bash-completion/completions/apko
|
||||
install -Dm644 "$builddir"/apko.fish "/out"/usr/share/fish/vendor_completions.d/apko.fish
|
||||
install -Dm644 "$builddir"/apko.zsh "/out"/usr/share/zsh/site-functions/_apko
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
@@ -14,6 +14,7 @@ compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
subdir = "cmd/atlas"
|
||||
|
||||
# buildInputs de nix (no usados con CGO off): go
|
||||
[deps]
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
# - el build usa el lab de hammer (zig-cc / musl estático), NO el stdenv de nix ⇒ revisá
|
||||
# compiler/link/phases y adaptá hasta que compile.
|
||||
# - las deps van con su nombre NIX; remapealas a las recetas del corpus si difieren.
|
||||
name = "go-containerregistry"
|
||||
name = "crane"
|
||||
version = "0.21.6"
|
||||
|
||||
[source]
|
||||
@@ -13,7 +13,7 @@ commit = "v0.21.6"
|
||||
compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
flags = ["./cmd/crane"]
|
||||
|
||||
# buildInputs de nix (no usados con CGO off): go
|
||||
[deps]
|
||||
|
||||
@@ -14,6 +14,8 @@ compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
subdir = "go"
|
||||
cgo = true
|
||||
|
||||
# buildInputs de nix (no usados con CGO off): go, icu4c
|
||||
[deps]
|
||||
|
||||
@@ -9,7 +9,6 @@ tarball = "https://github.com/anchore/grype/archive/v0.111.0/grype-0.111.0.tar.g
|
||||
# FIXME sha256: el wrapper lo calcula (Alpine publica sha512). sha512 de Alpine:
|
||||
# sha512 = "109662075d13ed6b397c3624679b52f49c2713d9bfc5562750ff2892c6f81810f616ffbb218bdfa31a8beae7331b0ff3d446de4cd9f295033afb527e74be1a0f"
|
||||
sha256 = "01d60c3e785f635da8f060712df2a901025386b740eb173e365ae0c263e66792"
|
||||
patches = ["disable-update-check.patch"]
|
||||
|
||||
[build]
|
||||
compiler = "zig-cc"
|
||||
|
||||
@@ -14,6 +14,7 @@ compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
subdir = "src"
|
||||
|
||||
# buildInputs de nix (no usados con CGO off): go
|
||||
[deps]
|
||||
|
||||
@@ -14,30 +14,8 @@ sha256 = "4b20d65194e5462264c784f2968de65fcd7aba8e9efa37aa9b1fadc13b29699b"
|
||||
compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
flags = ["./cmd/staticcheck"]
|
||||
|
||||
[build.phases]
|
||||
# de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático):
|
||||
compile = '''
|
||||
_abuild_phase() {
|
||||
export CGO_CPPFLAGS="$CPPFLAGS"
|
||||
export CGO_CFLAGS="$CFLAGS"
|
||||
export CGO_CXXFLAGS="$CXXFLAGS"
|
||||
export CGO_LDFLAGS="$LDFLAGS"
|
||||
|
||||
mkdir -p bin
|
||||
go build -o ./bin ./...
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
# de package() de Alpine (traducido $pkgdir→/out):
|
||||
install = '''
|
||||
_abuild_phase() {
|
||||
install -p -Dm755 -t "/out/usr/bin/" bin/*
|
||||
|
||||
install -Dm644 "LICENSE" "/out/usr/share/licenses/staticcheck/LICENSE"
|
||||
install -Dm644 "LICENSE-THIRD-PARTY" \
|
||||
"/out/usr/share/licenses/staticcheck/LICENSE-THIRD-PARTY"
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
@@ -15,31 +15,8 @@ patches = ["disable-update-check.patch"]
|
||||
compiler = "zig-cc"
|
||||
target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
flags = ["./cmd/syft"]
|
||||
|
||||
[build.phases]
|
||||
# de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático):
|
||||
compile = '''
|
||||
_abuild_phase() {
|
||||
go build -ldflags "
|
||||
-X main.version=1.42.4
|
||||
" \
|
||||
-o bin/syft ./cmd/syft
|
||||
|
||||
bin/syft completion bash >syft.bash
|
||||
bin/syft completion fish >syft.fish
|
||||
bin/syft completion zsh >syft.zsh
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
# de package() de Alpine (traducido $pkgdir→/out):
|
||||
install = '''
|
||||
_abuild_phase() {
|
||||
install -Dm755 bin/syft -t "/out"/usr/bin/
|
||||
|
||||
install -Dm644 syft.bash "/out"/usr/share/bash-completion/completions/syft
|
||||
install -Dm644 syft.fish "/out"/usr/share/fish/vendor_completions.d/syft.fish
|
||||
install -Dm644 syft.zsh "/out"/usr/share/zsh/site-functions/_syft
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
@@ -16,21 +16,6 @@ target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
|
||||
[build.phases]
|
||||
# de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático):
|
||||
compile = '''
|
||||
_abuild_phase() {
|
||||
local sdk=$(go list -f '{{.Version}}' -m code.gitea.io/sdk/gitea)
|
||||
|
||||
go build -ldflags "-X main.Version=0.9.2 -X main.SDK=$sdk" -o tea
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
# de package() de Alpine (traducido $pkgdir→/out):
|
||||
install = '''
|
||||
_abuild_phase() {
|
||||
install -Dm755 "$builddir"/tea "/out"/usr/bin/tea
|
||||
install -Dm644 "$srcdir"/bash_autocomplete "/out"/usr/share/bash-completion/completions/tea
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
@@ -18,3 +18,13 @@ flags = []
|
||||
# buildInputs de nix (no usados con CGO off): go
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
[build.phases]
|
||||
# = el compile Go generado por el lab + GOEXPERIMENT=jsonv2: trivy 0.72 importa
|
||||
# encoding/json/v2, que en go 1.26 sigue detrás del experimento (build constraints
|
||||
# excluyen esos fuentes sin el flag).
|
||||
compile = '''
|
||||
export GOCACHE=/src/.gocache GOTMPDIR=/src/.gotmp GOPATH=/tmp/gopath GOTOOLCHAIN=local CGO_ENABLED=0 GOFLAGS=-mod=vendor GOPROXY=off GOBIN=/out/usr/bin GOEXPERIMENT=jsonv2
|
||||
mkdir -p /src/.gotmp
|
||||
go install -trimpath -ldflags=-buildid= ./cmd/trivy
|
||||
'''
|
||||
|
||||
@@ -16,21 +16,6 @@ target = "x86_64-linux-musl"
|
||||
link = "static"
|
||||
flags = []
|
||||
|
||||
[build.phases]
|
||||
# de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático):
|
||||
compile = '''
|
||||
_abuild_phase() {
|
||||
go build
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
# de package() de Alpine (traducido $pkgdir→/out):
|
||||
install = '''
|
||||
_abuild_phase() {
|
||||
install -Dm755 xq /out/usr/bin/xq
|
||||
install -Dm644 README.md "/out/usr/share/doc/xq/README"
|
||||
install -Dm644 LICENSE "/out"/usr/share/licenses/xq/LICENSE
|
||||
install -Dm644 docs/xq.man /out/usr/share/man/man1/xq.1
|
||||
}
|
||||
_abuild_phase
|
||||
'''
|
||||
|
||||
[deps]
|
||||
build = ["go"]
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
# staged-fallidos-go — purga 2026-07-05
|
||||
|
||||
Triage de la cola `incoming-go` que giraba en falso (40/52 fallaban por ciclo, ~8h).
|
||||
Causa mayor de los "fallo (ver log)" genéricos: ENOSPC — los giants vendoreando en
|
||||
paralelo llevaban el disco del VPS a 96–97% (baseline ~90% por modcache acumulado);
|
||||
tras la purga de caches el baseline volvió a 75% y los sanos avanzan.
|
||||
|
||||
## Misimports (proyecto equivocado, NO reintroducir sin re-vetear)
|
||||
- `gf` — pide libx11 ⇒ es el frontend de GDB, no el wrapper de grep (tomnomnom/gf)
|
||||
- `httpstat` — pide setuptools ⇒ es el de Python
|
||||
- `mc` — pide unzip ⇒ Midnight Commander, no minio-client
|
||||
- `polaris` — cargo vendor ⇒ es el music-server en Rust, no el de Fairwinds
|
||||
- `jc` — sin main Go ⇒ es la herramienta Python
|
||||
- `dbgate` — tarball raro (Electron app)
|
||||
- `jsonnet` — pide jekyll ⇒ el C++ de google, no go-jsonnet
|
||||
|
||||
## Frontera CGO (libs C externas: gpgme/tree-sitter/oto)
|
||||
- `skopeo`, `operator-sdk` — gpgme (build constraints excluyen los fuentes)
|
||||
- `vale` — go-tree-sitter
|
||||
- `gtt` — oto (audio)
|
||||
- `gross` — proyecto C con c-ares, ni siquiera es Go
|
||||
|
||||
## go:embed de assets generados (necesitan node/manifiestos pre-build)
|
||||
- `fluxcd` — cmd/flux/manifests.embed.go: manifests/*.yaml no existen sin generación
|
||||
- `frp` — web/frpc/embed.go: falta dist del frontend
|
||||
- `forgejo` — dep nodejs (frontend)
|
||||
- `woodpecker` — dep go-swag + frontend
|
||||
- `kubetail` — dashboard web multimódulo
|
||||
|
||||
## Multimódulo / make hostil
|
||||
- `etcd` — make + módulos anidados + git ls-remote en build (red)
|
||||
- `gitlab-runner` — necesita $srcdir/tags.json de Alpine + GO111MODULE=auto
|
||||
|
||||
## Otros
|
||||
- `assetfinder` — sin go.mod (era GOPATH) ⇒ el vendor no aplica
|
||||
- `gotop` — go.mod lang 1.16 < unsafe.Slice (1.17), ya diferido antes
|
||||
- `wuzz` — deps muertas (go mod download falla)
|
||||
- `tilt` — go mod vendor falla en module-auth (checksum)
|
||||
- `syncthing` — build constraints excluyen todos los fuentes en /src
|
||||
|
||||
Los patches de gross/gitlab-runner/woodpecker viajan acá con sus recetas.
|
||||
Reference in New Issue
Block a user