fix(agent): correct version log, bump to v0.3.2, increase tailscale timeout

- Replace hardcoded AGENT_VERSION constant with injected version variable
- Bump agent version to 0.3.2
- Increase tailscale up/status timeout from 60s to 120s
This commit is contained in:
EduBox Dev
2026-06-23 18:29:21 +00:00
parent d090f67bff
commit 3a3e3ed202
3 changed files with 4 additions and 7 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
set -e set -e
VERSION="0.3.1" VERSION="0.3.2"
APP_NAME="studioE5" APP_NAME="studioE5"
BIN_NAME="studioE5-agent" BIN_NAME="studioE5-agent"
LDFLAGS="-X main.version=${VERSION}" LDFLAGS="-X main.version=${VERSION}"
+2 -5
View File
@@ -12,10 +12,7 @@ import (
// version is injected at build time via -ldflags "-X main.version=X.Y.Z" // version is injected at build time via -ldflags "-X main.version=X.Y.Z"
var version = "dev" var version = "dev"
const ( const APP_NAME = "studioE5"
AGENT_VERSION = "0.3.0"
APP_NAME = "studioE5"
)
var ( var (
dataDir = flag.String("data-dir", "./studioE5-data", "Répertoire de données") dataDir = flag.String("data-dir", "./studioE5-data", "Répertoire de données")
@@ -59,7 +56,7 @@ func main() {
log.Fatalf("Cannot save config: %v", err) log.Fatalf("Cannot save config: %v", err)
} }
log.Printf("[%s Agent] version=%s node=%s data-dir=%s server=%s", APP_NAME, AGENT_VERSION, cfg.NodeID, *dataDir, cfg.Server) log.Printf("[%s Agent] version=%s node=%s data-dir=%s server=%s", APP_NAME, version, cfg.NodeID, *dataDir, cfg.Server)
if *uiEnabled { if *uiEnabled {
go startUI(*dataDir, cfg.NodeID, cfg.Server) go startUI(*dataDir, cfg.NodeID, cfg.Server)
+1 -1
View File
@@ -93,7 +93,7 @@ func startTailscale(dataDir, nodeID, headscaleURL, authKey string) (string, erro
time.Sleep(1 * time.Second) time.Sleep(1 * time.Second)
// Bring the interface up with the auth key. // Bring the interface up with the auth key.
ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second) ctx, cancel := context.WithTimeout(context.Background(), 120*time.Second)
defer cancel() defer cancel()
upArgs := []string{ upArgs := []string{