[PR #346] [MERGED] Fix ip allocation bug, make integration tests faster #1397

Closed
opened 2025-12-29 02:29:55 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/juanfont/headscale/pull/346
Author: @kradalby
Created: 2/22/2022
Status: Merged
Merged: 2/25/2022
Merged by: @kradalby

Base: mainHead: integration-test-concurrent-join


📝 Commits (10+)

  • 8dca405 Test if we can join headscale in parallell to speed up
  • fe2f75d Allow integration test to retry
  • f7eeb97 Add timeout
  • 4962335 Remove dependency on CGO
  • 7e6e093 Merge branch 'integration-test-concurrent-join' of github.com:kradalby/headscale into integration-test-concurrent-join
  • 638a84a Merge branch 'main' into integration-test-concurrent-join
  • fb85c78 Fail integration tests fast
  • 9687e67 Remove retry from integration tests
  • 189e883 Resolve merge
  • eda0a9f Lock allocation of IP address

📊 Changes

10 files changed (+137 additions, -75 deletions)

View changed files

📝 .github/workflows/test-integration.yml (+1 -1)
📝 CHANGELOG.md (+7 -1)
📝 Makefile (+1 -1)
📝 api.go (+5 -0)
📝 app.go (+2 -0)
📝 integration_test.go (+60 -45)
📝 machine.go (+3 -0)
📝 oidc.go (+4 -0)
📝 utils.go (+30 -21)
📝 utils_test.go (+24 -6)

📄 Description

This PR fixes an issue where we did not ensure that IPs were allocated in a concurrency safe way.

In addition, it makes the integration tests faster (and hopefully more reliable), and if they fail, they "fail fast" and not try to run the whole suite.


🔄 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/346 **Author:** [@kradalby](https://github.com/kradalby) **Created:** 2/22/2022 **Status:** ✅ Merged **Merged:** 2/25/2022 **Merged by:** [@kradalby](https://github.com/kradalby) **Base:** `main` ← **Head:** `integration-test-concurrent-join` --- ### 📝 Commits (10+) - [`8dca405`](https://github.com/juanfont/headscale/commit/8dca40535fc3df976b3fdc847283e9c07e186028) Test if we can join headscale in parallell to speed up - [`fe2f75d`](https://github.com/juanfont/headscale/commit/fe2f75d13dd28bfc8ce1fc4be56cfed0447460ea) Allow integration test to retry - [`f7eeb97`](https://github.com/juanfont/headscale/commit/f7eeb979fb01d09a8b0b0d014a69691945d20692) Add timeout - [`4962335`](https://github.com/juanfont/headscale/commit/49623358604d02401581e7d9388883f4bbb39d93) Remove dependency on CGO - [`7e6e093`](https://github.com/juanfont/headscale/commit/7e6e093f175b71264e62d11d591abecd45125320) Merge branch 'integration-test-concurrent-join' of github.com:kradalby/headscale into integration-test-concurrent-join - [`638a84a`](https://github.com/juanfont/headscale/commit/638a84adb90329873919e6ffe9aec2fce67bf91e) Merge branch 'main' into integration-test-concurrent-join - [`fb85c78`](https://github.com/juanfont/headscale/commit/fb85c78e8a32a12c8befb0f95bea138aeeee2cf2) Fail integration tests fast - [`9687e67`](https://github.com/juanfont/headscale/commit/9687e6768d1383e87843724e17909b87e3779e14) Remove retry from integration tests - [`189e883`](https://github.com/juanfont/headscale/commit/189e883f911ff4f938a7b9ca2eddac7a6f8a07aa) Resolve merge - [`eda0a9f`](https://github.com/juanfont/headscale/commit/eda0a9f88a694c62afc858202d144e0a62019cf7) Lock allocation of IP address ### 📊 Changes **10 files changed** (+137 additions, -75 deletions) <details> <summary>View changed files</summary> 📝 `.github/workflows/test-integration.yml` (+1 -1) 📝 `CHANGELOG.md` (+7 -1) 📝 `Makefile` (+1 -1) 📝 `api.go` (+5 -0) 📝 `app.go` (+2 -0) 📝 `integration_test.go` (+60 -45) 📝 `machine.go` (+3 -0) 📝 `oidc.go` (+4 -0) 📝 `utils.go` (+30 -21) 📝 `utils_test.go` (+24 -6) </details> ### 📄 Description This PR fixes an issue where we did not ensure that IPs were allocated in a concurrency safe way. In addition, it makes the integration tests faster (and hopefully more reliable), and if they fail, they "fail fast" and not try to run the whole suite. --- <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 02:29:55 +01:00
adam closed this issue 2025-12-29 02:29:55 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#1397