From 60b0ebc852ad47b70125e30f4dcc8a00c1e57c33 Mon Sep 17 00:00:00 2001 From: Pulse Monitor Date: Sat, 23 Aug 2025 21:54:14 +0000 Subject: [PATCH] improve: include setup code in command for easy Proxmox shell usage - The generated command now includes PULSE_SETUP_CODE environment variable - Users can simply copy-paste the command in Proxmox shell without needing to type the code - Makes the setup process more streamlined for the primary use case --- internal/api/config_handlers.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/api/config_handlers.go b/internal/api/config_handlers.go index 68fde172a..e2bec169d 100644 --- a/internal/api/config_handlers.go +++ b/internal/api/config_handlers.go @@ -2514,9 +2514,10 @@ func (h *ConfigHandlers) HandleSetupScriptURL(w http.ResponseWriter, r *http.Req pulseURL, req.Type, encodedHost, pulseURL, backupPerms) // Return the URL, command, and setup code + // Include the setup code in the command for easy copy-paste in Proxmox shell response := map[string]interface{}{ "url": scriptURL, - "command": fmt.Sprintf(`curl -sSL "%s" | bash`, scriptURL), + "command": fmt.Sprintf(`PULSE_SETUP_CODE=%s curl -sSL "%s" | bash`, code, scriptURL), "setupCode": code, // The user needs to see this "expires": expiry.Unix(), }