feat: reveal saved server deployment inputs
This commit is contained in:
@@ -37,6 +37,21 @@ func (h *coreHandlers) serverInstanceCreateWorkflow(w http.ResponseWriter, r *ht
|
||||
writeJSON(w, http.StatusOK, dto.ServerLifecycleFromDomain(result))
|
||||
}
|
||||
|
||||
// serverDeploymentReveal explicitly returns saved deployment paths and commands
|
||||
// to an authorized server manager. Ordinary deployment views remain redacted.
|
||||
func (h *coreHandlers) serverDeploymentReveal(w http.ResponseWriter, r *http.Request) {
|
||||
if r.Method != http.MethodGet {
|
||||
writeMethodNotAllowed(w, http.MethodGet)
|
||||
return
|
||||
}
|
||||
reveal, err := h.core.RevealServerDeploymentForSession(bearerToken(r), r.PathValue("id"))
|
||||
if err != nil {
|
||||
writeServiceError(w, err)
|
||||
return
|
||||
}
|
||||
writeJSON(w, http.StatusOK, dto.ServerDeploymentRevealFromDomain(reveal))
|
||||
}
|
||||
|
||||
// serverDeployment reads safe deployment metadata or updates protected deployment input.
|
||||
func (h *coreHandlers) serverDeployment(w http.ResponseWriter, r *http.Request) {
|
||||
switch r.Method {
|
||||
|
||||
Reference in New Issue
Block a user