feat(handler): set Content-Type header to application/json in agent response

This commit is contained in:
yusing
2026-01-09 00:37:07 +08:00
parent bf227f280c
commit 7c65a13788

View File

@@ -50,6 +50,7 @@ func NewAgentHandler() http.Handler {
Name: env.AgentName,
Runtime: env.Runtime,
}
w.Header().Set("Content-Type", "application/json")
sonic.ConfigDefault.NewEncoder(w).Encode(agentInfo)
})
mux.HandleEndpoint("GET", agent.EndpointHealth, CheckHealth)