Add necessary refresh apitypes (#1299)

This change adds the apitypes required to make refresh-style updates
work in the PPC and in the service.
This commit is contained in:
Joe Duffy 2018-04-30 17:42:24 -07:00 committed by GitHub
parent fd3ddda917
commit b22a28ed34
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -15,6 +15,8 @@ const (
DeployUpdate UpdateKind = "update"
// PreviewUpdate is a preview of an update, without impacting resources.
PreviewUpdate UpdateKind = "preview"
// RefreshUpdate is an update that came from a refresh operation.
RefreshUpdate UpdateKind = "refresh"
// DestroyUpdate is an update which removes all resources.
DestroyUpdate UpdateKind = "destroy"
)

View file

@ -151,9 +151,11 @@ type UpdateProgram struct {
// Analyzers is the set of analyzers to run when this program is executed.
Analyzers []string `json:"analyzers"`
// Destroy indicates whether or not this program is the nil program (i.e. the program that generates no
// resources).
// Destroy indicates whether or not this program is the nil program (i.e. the program that generates no resources).
Destroy bool `json:"destroy"`
// Refresh is true if this is a refresh-style update, which simply takes state from the current cloud resources.
Refresh bool `json:"refresh"`
}
// CreateUpdateRequest describe the data provided as the body of a request to the `POST /updates` endpoint of