Kristoffer Dalby
5d44138d40
.github: give servertest 40 minutes
...
The package already used nearly all of 20m; the reauth-wake replay
tests push it past and the run panics mid-progress.
Updates #3370
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
568eeaed2f
CHANGELOG: shorten the restart entry
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
e8a318db71
servertest: split the relogin replay out of apply
...
apply crossed the gocyclo limit.
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
ef05aefc2b
CHANGELOG: note restarts that send another auth key
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
3cbf7ecdb8
github: run the restart integration test
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
06b57a82b1
integration: restart a tagged node with another spent key
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
5e22477e4b
servertest: restart a real tsnet node with another key
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
27dedae3c1
servertest: replay the reauth-wake captures
...
Tags asked for while awake stay a known gap.
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
6d36263ac7
servertest: add reauth-wake captures from SaaS
...
tailscaled and tsnet restarting with another key, and asking for tags.
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
a1f1e30e65
servertest: replay restarts that send an auth key
...
tsnet sends TS_AUTHKEY on every start; up --advertise-tags may send none.
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
2765031898
hscontrol: log refused registrations
...
The client only retries, so the log is the operator's one sign.
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
7a3d2e88fe
state: wake a node under its own node key, whatever key it sends
...
As on SaaS, the key a restart sends is not judged, spent or applied; only
a new node key logs in. Known tsnet and container nodes no longer drop.
Updates #3370
2026-11-11 18:12:34 +01:00
Kristoffer Dalby
095844e626
derp/server: return STUN bind errors to Serve
...
log.Fatal exited the process and skipped the graceful shutdown.
Fixes #3499
2026-11-11 18:02:00 +01:00
Kristoffer Dalby
79a036ba97
hscontrol: stop Serve through its context
...
Serve only stopped on signals; a failed listener left it half running.
Updates #3499
2026-11-11 18:02:00 +01:00
Kristoffer Dalby
ce295d6782
nix, docs: regenerate config reference
...
Updates #3588
2026-11-11 17:54:31 +01:00
Kristoffer Dalby
f75c7cf059
dns: read non-string provider settings from file:
...
A file: value of a non-string setting, such as acme-dns config,
is the JSON in that file; checks leave it unread.
Fixes #3588
2026-11-11 17:54:31 +01:00
Kristoffer Dalby
c7bfe5b4f7
integration/k3sic: disable the k3s cloud controller
...
Its CCM can exit "forbidden" before its RBAC applies, restart-looping k3s.
Updates #3125
2026-11-11 17:39:17 +01:00
Kristoffer Dalby
07859e5ff6
types, docs, nix: regenerate config docs for write_ahead_log
...
Updates #1926
2026-11-11 17:32:36 +01:00
Kristoffer Dalby
b7995a311c
db: turn off WAL when database.sqlite.write_ahead_log is false
...
Since 0.27.0 false only skipped wal_autocheckpoint. Now DELETE journal,
synchronous=FULL; a database left in WAL mode is converted on open.
Updates #1926
2026-11-11 17:32:36 +01:00
Kristoffer Dalby
5a5290c174
db: validate the sqlite schema on one connection
...
squibble nests queries; a second connection's auto_vacuum pragma writes,
and without WAL that write waits on the first one's read until busy_timeout.
Updates #1926
2026-11-11 17:32:36 +01:00
Kristoffer Dalby
051a3f102a
config: reject an empty log.level and log.format
...
As the other enums do; --running showed "" for the info/text in effect.
Updates #1926
2026-11-11 17:24:01 +01:00
Kristoffer Dalby
8b711055fb
hscontrol: serialise OIDC user lookup and create
...
Concurrent first logins of one identity both missed the lookup and
both created; the loser hit the unique index and returned 500.
2026-11-11 17:07:35 +01:00
Kristoffer Dalby
687bb762e0
hscontrol: build tailsql DSN with sqliteconfig
...
Its hand-built file: URI did not escape the path, so tailsql
read another file than headscale. Add Config.ReadOnly for mode=ro.
2026-11-11 16:58:07 +01:00
Kristoffer Dalby
1a44a0ac54
sqliteconfig: escape database path in ToURL
...
SQLite ends a file: URI path at '?' or '#' and decodes '%',
so such a path opened a different file than configured.
2026-11-11 16:58:07 +01:00
Kristoffer Dalby
b6e6c6f08c
CHANGELOG: deleted nodes get a map 404
...
Updates #3688
2026-11-11 16:45:24 +01:00
Kristoffer Dalby
30a31e77cf
integration: expect NeedsLogin after deletion only from 1.106
...
Older clients keep retrying a map 404, as against Tailscale.
Updates #3688
2026-11-11 16:45:24 +01:00
Kristoffer Dalby
2e03bee425
servertest: check a deleted tsnet node does not spin
...
Updates #3688
2026-11-11 16:45:24 +01:00
Kristoffer Dalby
ca512f2c57
noise: answer a deleted node's map request with 404
...
As Tailscale does. A netmap resets the client's map backoff, so ending
the stream after one made it re-poll every few milliseconds.
Fixes #3688
2026-11-11 16:45:24 +01:00
Kristoffer Dalby
934a1f12b8
docs: regenerate configuration reference
...
Updates #1926
2026-11-11 16:42:44 +01:00
Kristoffer Dalby
2cf95feec6
cli: fail at once on an empty unix_socket
...
It retried until cli.timeout, then said "missing address".
Updates #1926
2026-11-11 16:42:44 +01:00
Kristoffer Dalby
56a644a28a
types: require derp.server.region_id with the embedded server
...
Unset, it was 0, a region clients never connect to.
Updates #1926
2026-11-11 16:42:44 +01:00
Kristoffer Dalby
e35af45066
config: reject empty list items
...
A resolver became the local one, an allowed user one without an email.
Updates #1926
2026-11-11 16:42:44 +01:00
Kristoffer Dalby
68424bbb4a
types: reject empty values serve cannot use
...
unix_socket, half a TLS keypair, ACME without http_listen or cache_dir.
Document empty postgres settings. Updates #1926
2026-11-11 16:42:44 +01:00
Kristoffer Dalby
a2d8eb42e7
cli: print a config load error like every other command error
...
initConfig logged it as one FTL line, newlines escaped, with the build path.
Updates #1926
2026-11-11 16:37:40 +01:00
Kristoffer Dalby
3e23f167c9
flake: update vendor hash for stunserver import
...
Updates #3573
2026-11-11 16:05:22 +01:00
Kristoffer Dalby
dd4a0edab8
derp/server: serve STUN with Tailscale's stunserver
...
Own loop answered IPv4 clients of a dual-stack socket with ::ffff:a.b.c.d.
Fixes #3573
2026-11-11 16:05:22 +01:00
Kristoffer Dalby
492c28f5bb
.github: run vouch as the headscale-bot App
...
GITHUB_TOKEN PRs wait for CI approval and cannot merge past main's
rules; the App is the ruleset bypass actor. Sync checks out main, so a
dispatch on another branch cannot squash that branch into main.
2026-11-11 15:19:25 +01:00
Kristoffer Dalby
38da2a9625
.github: open version bump PRs as the headscale-bot App
...
Juan's PAT authored the PR, so he could not approve it.
2026-11-11 15:19:25 +01:00
Kristoffer Dalby
727024ec52
tools/bump: hand publishing off to a separate step
...
Lets the gate run without a write token, and the token that
publishes be minted after a gate that can outlive it.
2026-11-11 15:19:25 +01:00
Kristoffer Dalby
d2dc13696a
config, cli, packaging, nix: stop restarting headscale on a configuration error
...
serve exits 78 (EX_CONFIG) when the configuration file it loaded is
wrong: format, syntax, keys or values. No file, an unreadable one, the
database and ports still exit 1, so systemd keeps retrying what can
heal. The deb unit and the NixOS module set RestartPreventExitStatus=78.
A parse error gives a position and fixed words, never the file's text.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
a23ea307df
packaging: start headscale only with a configuration it accepts
...
postinst starts or restarts headscale only when check config passes.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
4e8ddfef25
nix: keep only distro facts as module defaults
...
State paths, socket and disable_check_updates; headscale's defaults cover
the rest. headscale-docker gains a CA bundle to fetch HTTPS DERP maps.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
6247fc59e5
nix, docs: regenerate NixOS options and the configuration reference
...
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
b600c1f391
cli: print only the required keys with generate config --minimal
...
With every other key defaulted, server_url alone is a configuration.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
86129dd5ce
servertest: start a server from a loaded configuration
...
NewServerFromConfig serves a config unchanged; TestServerURLOnly proves a
server_url-only file or env config serves both ranges, tailnet.internal
and no DNS resolvers.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
f5f86e69d0
config: require listen_addr and the sqlite path
...
Empty values serve cannot use; empty server_url reads "is required".
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
2db863d5e6
config: clear a key from the environment with ""
...
A HEADSCALE_* value of "" means what key: "" means in a file, errors
included, so an env-only setup can clear a defaulted key. An empty
variable still counts as unset.
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
542fe8dd55
config: give every key but server_url a working default
...
server_url alone, in a file or HEADSCALE_SERVER_URL, now passes check config.
Fixes #3567
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
57a18b8c41
hscontrol: refresh the DERP map without blocking other scheduled tasks
...
Updates #1926
2026-11-11 15:02:16 +01:00
Kristoffer Dalby
fcb1d42b86
nix: check the configuration while building the system
...
check.config also runs `check config -f` on the generated file at build
time, native only, under the unit's environment.
Updates #1926
2026-11-11 15:02:16 +01:00