feat: reveal saved server deployment inputs
This commit is contained in:
@@ -865,6 +865,28 @@ type ServerDeploymentView struct {
|
||||
Revision int
|
||||
UpdatedAt time.Time
|
||||
Projection ServerDeploymentProjection
|
||||
LatestDispatch *ServerDeploymentDispatchEvidence
|
||||
}
|
||||
|
||||
// ServerDeploymentReveal contains an explicitly requested operator view of
|
||||
// persisted execution inputs. Runtime bindings are intentionally excluded.
|
||||
type ServerDeploymentReveal struct {
|
||||
ServerInstanceID string
|
||||
ServerRoot string
|
||||
WorkingDirectory string
|
||||
InstallCommand string
|
||||
StartCommand string
|
||||
StopCommand string
|
||||
StatusCommand string
|
||||
}
|
||||
|
||||
// ServerDeploymentDispatchEvidence proves what Platform placed into the most
|
||||
// recent lifecycle job without exposing its protected contents.
|
||||
type ServerDeploymentDispatchEvidence struct {
|
||||
JobID string
|
||||
JobState JobState
|
||||
DeploymentRevision int
|
||||
DeploymentDefinitionIncluded bool
|
||||
}
|
||||
|
||||
type ConfigDiffLine struct {
|
||||
@@ -1790,6 +1812,10 @@ func CopyServerDeploymentUpdate(update ServerDeploymentUpdate) ServerDeploymentU
|
||||
|
||||
func CopyServerDeploymentView(view ServerDeploymentView) ServerDeploymentView {
|
||||
view.CreateInputs = CopyStringMap(view.CreateInputs)
|
||||
if view.LatestDispatch != nil {
|
||||
copy := *view.LatestDispatch
|
||||
view.LatestDispatch = ©
|
||||
}
|
||||
return view
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user