gokrazy, tstest, cmd/vnet: switch amd64 kernel to gokrazy/kernel.amd64

The tailscale/gokrazy-kernel module was a fork of rtr7/kernel that
stalled at Linux 6.8.9 (July 2024). All of the kernel config options we
had added in that fork (ENA, Xen for EC2, virtio-mmio for qemu microvm,
virtio RNG, IPv6 policy routing, netlink diag, etc) are now present in
the gokrazy project's own gokrazy/kernel.amd64 module, which tracks
current kernel.org releases (Linux 7.1.3 as of this change) and is the
gokrazy project's supported kernel for x86_64 PCs and VMs.

Switch the tsapp and natlabapp images, the natlab VM tests, and the
CI workflow to gokrazy/kernel.amd64, drop the tailscale/gokrazy-kernel
dependency, and update gokrazy/kernel.arm64 to latest while here.

Verified with TestEasyEasy, TestJustIPv6, and TestTailscaleSSH in
tstest/natlab/vmtest with --run-vm-tests.

Updates #1866

Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
Change-Id: I90c3765a4e18f5609b4d77b51ac38d17c8e3688a
This commit is contained in:
Brad Fitzpatrick
2026-07-15 11:45:02 -04:00
committed by Brad Fitzpatrick
parent 4660a961eb
commit 0fb8226708
14 changed files with 27 additions and 27 deletions
+3 -3
View File
@@ -165,13 +165,13 @@ jobs:
key: natlab-gokrazy-${{ github.sha }}
# The gokrazy-based tests boot the kernel directly from
# vmlinuz that ships in the tailscale/gokrazy-kernel module.
# vmlinuz that ships in the gokrazy/kernel.amd64 module.
# Tests look it up under GOMODCACHE via findKernelPath, so the
# module has to be present even though no Go source imports it
# in the test package itself.
- name: Download gokrazy-kernel module
- name: Download kernel.amd64 module
run: |
./tool/go mod download github.com/tailscale/gokrazy-kernel
./tool/go mod download github.com/gokrazy/kernel.amd64
- name: Run ${{ matrix.test }}
# Per-test timeout is well above the few-minute typical runtime
+1 -1
View File
@@ -12,7 +12,7 @@ set -eux
qemu-system-x86_64 -M microvm,isa-serial=off \
-m 1G \
-nodefaults -no-user-config -nographic \
-kernel $HOME/src/github.com/tailscale/gokrazy-kernel/vmlinuz \
-kernel $HOME/src/github.com/gokrazy/kernel.amd64/vmlinuz \
-append "console=hvc0 root=PARTUUID=60c24cc1-f3f9-427a-8199-76baa2d60001/PARTNROFF=1 ro init=/gokrazy/init panic=10 oops=panic pci=off nousb tsc=unstable clocksource=hpet tailscale-tta=1 tailscaled.env=TS_DEBUG_RAW_DISCO=1 ${EXTRA_ARG}" \
-drive id=blk0,file=$HOME/src/tailscale.com/gokrazy/natlabapp.img,format=raw \
-device virtio-blk-device,drive=blk0 \
+1 -1
View File
@@ -173,4 +173,4 @@
});
};
}
# nix-direnv cache busting line: sha256-48z3snHndd96fJtvNbK+fnzTs4W6VfrWxL1l8HXRAQI=
# nix-direnv cache busting line: sha256-y7ZgrxWeeUYG+FKL9Ym8QmqaQsGnUVc9GXkA4na/AJI=
+2 -2
View File
@@ -4,7 +4,7 @@
"sri": "sha256-TwIaPmGVHO9ZwdaO/jDStgWGQtKa4smS3er1i5aTNTw="
},
"vendor": {
"goModSum": "sha256-6RZ9xk8/PtnZA9Y7sAggn40lESnQFgYWwIPuv4IOhDg=",
"sri": "sha256-48z3snHndd96fJtvNbK+fnzTs4W6VfrWxL1l8HXRAQI="
"goModSum": "sha256-sKqNU5HU/3NOzvAYcdYsMocYsvr1xpM4Ch4SWsH9dVg=",
"sri": "sha256-y7ZgrxWeeUYG+FKL9Ym8QmqaQsGnUVc9GXkA4na/AJI="
}
}
+2 -2
View File
@@ -52,7 +52,8 @@ require (
github.com/gokrazy/breakglass v0.0.0-20251229072214-9dbc0478d486
github.com/gokrazy/firmware v0.0.0-20260522070551-527ce0ed43cf
github.com/gokrazy/gokrazy v0.0.0-20260418085648-c38c3134b8a7
github.com/gokrazy/kernel.arm64 v0.0.0-20260403054012-807489e0272a
github.com/gokrazy/kernel.amd64 v0.0.0-20260705070735-de680abf072b
github.com/gokrazy/kernel.arm64 v0.0.0-20260705071517-37841c4d6ff1
github.com/gokrazy/kernel.rpi v0.0.0-20251127164438-9778ec0261de
github.com/gokrazy/rpi-eeprom v0.0.0-20260518070910-95f7328a8228
github.com/gokrazy/serial-busybox v0.0.0-20250119153030-ac58ba7574e7
@@ -102,7 +103,6 @@ require (
github.com/tailscale/depaware v0.0.0-20251001183927-9c2ad255ef3f
github.com/tailscale/gliderssh v0.3.4-0.20260603235856-90d7dcbcbf38
github.com/tailscale/goexpect v0.0.0-20210902213824-6e8c725cea41
github.com/tailscale/gokrazy-kernel v0.0.0-20240728225134-3d23beabda2e
github.com/tailscale/golang-x-crypto v0.0.0-20250404221719-a5573b049869
github.com/tailscale/hujson v0.0.0-20260302212456-ecc657c15afd
github.com/tailscale/mkctr v0.0.0-20260107121656-ea857e3e500b
+4 -4
View File
@@ -522,8 +522,10 @@ github.com/gokrazy/gokrazy v0.0.0-20260418085648-c38c3134b8a7/go.mod h1:NtMkrFeD
github.com/gokrazy/internal v0.0.0-20200407075822-660ad467b7c9/go.mod h1:LA5TQy7LcvYGQOy75tkrYkFUhbV2nl5qEBP47PSi2JA=
github.com/gokrazy/internal v0.0.0-20251208203110-3c1aa9087c82 h1:4ghNfD9NaZLpFrqQiBF6mPVFeMYXJSky38ubVA4ic2E=
github.com/gokrazy/internal v0.0.0-20251208203110-3c1aa9087c82/go.mod h1:dQY4EMkD4L5ZjYJ0SPtpgYbV7MIUMCxNIXiOfnZ6jP4=
github.com/gokrazy/kernel.arm64 v0.0.0-20260403054012-807489e0272a h1:fa11POmSLo6fkkcqc+RUIyiqGJzBAOHEe/CCHAA/NGc=
github.com/gokrazy/kernel.arm64 v0.0.0-20260403054012-807489e0272a/go.mod h1:WWx72LXHEesuJxbopusRfSoKJQ6ffdwkT0DZditdrLo=
github.com/gokrazy/kernel.amd64 v0.0.0-20260705070735-de680abf072b h1:H9m4mwDqTyQG0AKVviBQp09T3OrY1X3tHNyrJCbqJfY=
github.com/gokrazy/kernel.amd64 v0.0.0-20260705070735-de680abf072b/go.mod h1:bcNzFtcy9x+l7l4KUqOkVFyIqrtWn8U92Jo9ZEOckbw=
github.com/gokrazy/kernel.arm64 v0.0.0-20260705071517-37841c4d6ff1 h1:MYq3OcTlEz46i/DZxG3c6ePjE6Te/024cPW2VHTBVAs=
github.com/gokrazy/kernel.arm64 v0.0.0-20260705071517-37841c4d6ff1/go.mod h1:WWx72LXHEesuJxbopusRfSoKJQ6ffdwkT0DZditdrLo=
github.com/gokrazy/kernel.rpi v0.0.0-20251127164438-9778ec0261de h1:RSLWj1Ska9s4cl+n/bC5LY4s8vLr+tZoO2vMm/wGP64=
github.com/gokrazy/kernel.rpi v0.0.0-20251127164438-9778ec0261de/go.mod h1:p5uBeUWKZVv3KJWWD6s9MpAjPjGJUe2CmKDML+5pm6U=
github.com/gokrazy/rpi-eeprom v0.0.0-20260518070910-95f7328a8228 h1:sLyorzF3zTdEiTvTUpctCIf14tZQFXTfayWBhn9QPG4=
@@ -1193,8 +1195,6 @@ github.com/tailscale/go-winio v0.0.0-20231025203758-c4f33415bf55 h1:Gzfnfk2TWrk8
github.com/tailscale/go-winio v0.0.0-20231025203758-c4f33415bf55/go.mod h1:4k4QO+dQ3R5FofL+SanAUZe+/QfeK0+OIuwDIRu2vSg=
github.com/tailscale/goexpect v0.0.0-20210902213824-6e8c725cea41 h1:/V2rCMMWcsjYaYO2MeovLw+ClP63OtXgCF2Y1eb8+Ns=
github.com/tailscale/goexpect v0.0.0-20210902213824-6e8c725cea41/go.mod h1:/roCdA6gg6lQyw/Oz6gIIGu3ggJKYhF+WC/AQReE5XQ=
github.com/tailscale/gokrazy-kernel v0.0.0-20240728225134-3d23beabda2e h1:tyUUgeRPGHjCZWycRnhdx8Lx9DRkjl3WsVUxYMrVBOw=
github.com/tailscale/gokrazy-kernel v0.0.0-20240728225134-3d23beabda2e/go.mod h1:7Mth+m9bq2IHusSsexMNyupHWPL8RxwOuSvBlSGtgDY=
github.com/tailscale/golang-x-crypto v0.0.0-20250404221719-a5573b049869 h1:SRL6irQkKGQKKLzvQP/ke/2ZuB7Py5+XuqtOgSj+iMM=
github.com/tailscale/golang-x-crypto v0.0.0-20250404221719-a5573b049869/go.mod h1:ikbF+YT089eInTp9f2vmvy4+ZVnW5hzX1q2WknxSprQ=
github.com/tailscale/hujson v0.0.0-20260302212456-ecc657c15afd h1:Rf9uhF1+VJ7ZHqxrG8pJ6YacmHvVCmByDmGbAWCc/gA=
+4 -4
View File
@@ -37,8 +37,8 @@ func TestTsappConfigs(t *testing.T) {
name: "tsapp",
app: "tsapp",
goarch: "amd64",
kernel: "github.com/tailscale/gokrazy-kernel",
firmware: "github.com/tailscale/gokrazy-kernel",
kernel: "github.com/gokrazy/kernel.amd64",
firmware: "github.com/gokrazy/kernel.amd64",
},
{
name: "tsapp-vm-arm64",
@@ -117,11 +117,11 @@ func findKernelPath(t *testing.T) string {
t.Fatalf("go env GOMODCACHE: %v", err)
}
for _, r := range mf.Require {
if r.Mod.Path == "github.com/tailscale/gokrazy-kernel" {
if r.Mod.Path == "github.com/gokrazy/kernel.amd64" {
return strings.TrimSpace(string(goModB)) + "/" + r.Mod.String() + "/vmlinuz"
}
}
t.Fatal("failed to find gokrazy-kernel in go.mod")
t.Fatal("failed to find kernel.amd64 in go.mod")
return ""
}
+1 -1
View File
@@ -24,7 +24,7 @@
"GOOS=linux",
"GOARCH=amd64"
],
"KernelPackage": "github.com/tailscale/gokrazy-kernel",
"KernelPackage": "github.com/gokrazy/kernel.amd64",
"FirmwarePackage": "",
"EEPROMPackage": "",
"InternalCompatibilityFlags": {
+1 -1
View File
@@ -7,8 +7,8 @@ package gokrazydeps
import (
_ "github.com/gokrazy/gokrazy/cmd/dhcp"
_ "github.com/gokrazy/kernel.amd64"
_ "github.com/gokrazy/serial-busybox"
_ "github.com/tailscale/gokrazy-kernel"
_ "github.com/tailscale/ts-gokrazy/gokrazyinit"
_ "tailscale.com/cmd/tailscale"
_ "tailscale.com/cmd/tailscaled"
+2 -2
View File
@@ -44,8 +44,8 @@
"GOOS=linux",
"GOARCH=amd64"
],
"KernelPackage": "github.com/tailscale/gokrazy-kernel",
"FirmwarePackage": "github.com/tailscale/gokrazy-kernel",
"KernelPackage": "github.com/gokrazy/kernel.amd64",
"FirmwarePackage": "github.com/gokrazy/kernel.amd64",
"InternalCompatibilityFlags": {
"InitImportPath": "github.com/tailscale/ts-gokrazy/gokrazyinit"
}
+1 -1
View File
@@ -11,8 +11,8 @@ import (
_ "github.com/gokrazy/gokrazy/cmd/dhcp"
_ "github.com/gokrazy/gokrazy/cmd/ntp"
_ "github.com/gokrazy/gokrazy/cmd/randomd"
_ "github.com/gokrazy/kernel.amd64"
_ "github.com/gokrazy/serial-busybox"
_ "github.com/tailscale/gokrazy-kernel"
_ "github.com/tailscale/ts-gokrazy/gokrazyinit"
_ "tailscale.com/cmd/tailscale"
_ "tailscale.com/cmd/tailscaled"
+1 -1
View File
@@ -16,4 +16,4 @@
) {
src = ./.;
}).shellNix
# nix-direnv cache busting line: sha256-48z3snHndd96fJtvNbK+fnzTs4W6VfrWxL1l8HXRAQI=
# nix-direnv cache busting line: sha256-y7ZgrxWeeUYG+FKL9Ym8QmqaQsGnUVc9GXkA4na/AJI=
+1 -1
View File
@@ -106,7 +106,7 @@ func findKernelPath(goMod string) (string, error) {
return "", err
}
for _, r := range mf.Require {
if r.Mod.Path == "github.com/tailscale/gokrazy-kernel" {
if r.Mod.Path == "github.com/gokrazy/kernel.amd64" {
return strings.TrimSpace(string(goModB)) + "/" + r.Mod.String() + "/vmlinuz", nil
}
}
+3 -3
View File
@@ -2071,17 +2071,17 @@ func findKernelPath(goMod string) (string, error) {
}
goModCache := strings.TrimSpace(string(goModCacheB))
// Parse go.mod to find gokrazy-kernel version.
// Parse go.mod to find kernel version.
for line := range strings.SplitSeq(string(b), "\n") {
line = strings.TrimSpace(line)
if strings.HasPrefix(line, "github.com/tailscale/gokrazy-kernel") {
if strings.HasPrefix(line, "github.com/gokrazy/kernel.amd64") {
parts := strings.Fields(line)
if len(parts) >= 2 {
return filepath.Join(goModCache, parts[0]+"@"+parts[1], "vmlinuz"), nil
}
}
}
return "", fmt.Errorf("gokrazy-kernel not found in %s", goMod)
return "", fmt.Errorf("kernel.amd64 not found in %s", goMod)
}
// PingRoute describes what connection type was used to transfer a Disco ping.