[PR #2741] [MERGED] derp: increase update frequency and harden on failures #2828

Closed
opened 2025-12-29 04:19:13 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/juanfont/headscale/pull/2741
Author: @kradalby
Created: 8/21/2025
Status: Merged
Merged: 8/22/2025
Merged by: @kradalby

Base: mainHead: kradalby/derp-times


📝 Commits (5)

  • 1c02b0d derp: increase update frequency to 3h
  • cce63a2 derp: add retry, do not replace if fails
  • 5e97884 changelog: update
  • e82b001 mapper: fix test with new derp init
  • 0c8765c derp: shuffle nodes per region

📊 Changes

10 files changed (+415 additions, -65 deletions)

View changed files

📝 CHANGELOG.md (+14 -1)
📝 config-example.yaml (+3 -4)
📝 hscontrol/app.go (+29 -14)
📝 hscontrol/derp/derp.go (+55 -26)
hscontrol/derp/derp_test.go (+284 -0)
📝 hscontrol/derp/server/derp_server.go (+6 -6)
📝 hscontrol/mapper/batcher_test.go (+7 -0)
📝 hscontrol/mapper/builder.go (+1 -1)
📝 hscontrol/state/state.go (+15 -13)
📝 hscontrol/types/config.go (+1 -0)

📄 Description

This commit changes the example config and default time for
how often we refresh the DERP map. If not changed, this
is typically Tailscales official map.

Second commit makes updating of the DERP map from file and url
more robust by retrying with exponential backoff if it fails
and upon failure, keep the old DERP map if we cannot successfully
build a new one.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/juanfont/headscale/pull/2741 **Author:** [@kradalby](https://github.com/kradalby) **Created:** 8/21/2025 **Status:** ✅ Merged **Merged:** 8/22/2025 **Merged by:** [@kradalby](https://github.com/kradalby) **Base:** `main` ← **Head:** `kradalby/derp-times` --- ### 📝 Commits (5) - [`1c02b0d`](https://github.com/juanfont/headscale/commit/1c02b0d45a0abada9a3b4cd560a52d9905ee32bc) derp: increase update frequency to 3h - [`cce63a2`](https://github.com/juanfont/headscale/commit/cce63a27d61b915b32be638bac354c6a1a041cfc) derp: add retry, do not replace if fails - [`5e97884`](https://github.com/juanfont/headscale/commit/5e9788475f128db7914a32b8a09921077c2cd05c) changelog: update - [`e82b001`](https://github.com/juanfont/headscale/commit/e82b001ce65f1606b108543bdf6ddbc78296a63f) mapper: fix test with new derp init - [`0c8765c`](https://github.com/juanfont/headscale/commit/0c8765c5a2e937ecfa1d64609f8776d7136a3f54) derp: shuffle nodes per region ### 📊 Changes **10 files changed** (+415 additions, -65 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+14 -1) 📝 `config-example.yaml` (+3 -4) 📝 `hscontrol/app.go` (+29 -14) 📝 `hscontrol/derp/derp.go` (+55 -26) ➕ `hscontrol/derp/derp_test.go` (+284 -0) 📝 `hscontrol/derp/server/derp_server.go` (+6 -6) 📝 `hscontrol/mapper/batcher_test.go` (+7 -0) 📝 `hscontrol/mapper/builder.go` (+1 -1) 📝 `hscontrol/state/state.go` (+15 -13) 📝 `hscontrol/types/config.go` (+1 -0) </details> ### 📄 Description This commit changes the example config and default time for how often we refresh the DERP map. If not changed, this is typically Tailscales official map. Second commit makes updating of the DERP map from file and url more robust by retrying with exponential backoff if it fails and upon failure, keep the old DERP map if we cannot successfully build a new one. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 04:19:13 +01:00
adam closed this issue 2025-12-29 04:19:13 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#2828