mirror of
https://github.com/juanfont/headscale.git
synced 2025-08-14 13:51:01 +02:00
ha fix
This commit is contained in:
parent
db0c78b83f
commit
bf9e748f96
@ -470,8 +470,9 @@ func (s *State) Disconnect(id types.NodeID) (change.ChangeSet, error) {
|
||||
now := time.Now()
|
||||
s.nodeStore.UpdateNode(id, func(n *types.Node) {
|
||||
n.LastSeen = ptr.To(now)
|
||||
// Do NOT mark as offline here - let the batcher's grace period handle it
|
||||
// This ensures DNS continues to work during logout
|
||||
// Mark as offline immediately in NodeStore - this is the source of truth
|
||||
// The batcher's grace period will still apply when sending to clients
|
||||
n.IsOnline = ptr.To(false)
|
||||
})
|
||||
|
||||
_, err := s.updateNodeTx(id, func(tx *gorm.DB) error {
|
||||
|
34
test_output.log
Normal file
34
test_output.log
Normal file
@ -0,0 +1,34 @@
|
||||
2025/08/06 13:42:02 Running pre-flight system checks...
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
2025/08/06 13:42:02 🔍 System Health Check Results
|
||||
2025/08/06 13:42:02 ================================
|
||||
2025/08/06 13:42:02 ✅ Docker Binary: Docker binary found
|
||||
2025/08/06 13:42:02 ✅ Docker Daemon: Docker daemon is running and accessible
|
||||
2025/08/06 13:42:02 ✅ Docker Context: Using Docker context: default
|
||||
2025/08/06 13:42:02 ✅ Docker Socket: Docker socket accessible (Server: 28.2.2)
|
||||
2025/08/06 13:42:02 ✅ Golang Image: Golang image golang:1.24.0 is available locally
|
||||
2025/08/06 13:42:02 ✅ Go Installation: go version go1.24.4 linux/amd64
|
||||
2025/08/06 13:42:02 ✅ Git Repository: Running in Git repository
|
||||
2025/08/06 13:42:02 ✅ Required Files: All required files found
|
||||
2025/08/06 13:42:02 ================================
|
||||
2025/08/06 13:42:02 ✅ All system checks passed - ready to run integration tests!
|
||||
2025/08/06 13:42:02 Running test: TestHASubnetRouterFailover
|
||||
2025/08/06 13:42:02 Go version: 1.24.0
|
||||
2025/08/06 13:42:02 Timeout: 30m0s
|
||||
2025/08/06 13:42:02 Use PostgreSQL: false
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
2025/08/06 13:42:02 Run ID: 20250806-134202-5uivan
|
||||
2025/08/06 13:42:02 Container name: headscale-test-suite-20250806-134202-5uivan
|
||||
2025/08/06 13:42:02 Logs directory: control_logs/20250806-134202-5uivan
|
||||
2025/08/06 13:42:02 Running pre-test cleanup...
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
Removed 2 test containers
|
||||
2025/08/06 13:42:02 Using Docker host from context 'default': unix:///var/run/docker.sock
|
||||
Removed 1 unused networks
|
||||
2025/08/06 13:42:03 Command: go test ./... -run TestHASubnetRouterFailover -failfast -timeout 30m0s -v
|
||||
2025/08/06 13:42:03 Image golang:1.24.0 is available locally
|
||||
2025/08/06 13:42:03 Using Docker socket: /var/run/docker.sock
|
||||
2025/08/06 13:42:03 Created container: 9e1c3ab2f9fad58d5056bae8d55f7c373653cb2b79590513fdd3e49efe4845f7
|
||||
2025/08/06 13:42:03 Starting test: TestHASubnetRouterFailover
|
Loading…
Reference in New Issue
Block a user