feat: Add template version warnings (#7483)

This commit is contained in:
Marcin Tojek
2023-05-12 11:21:49 +02:00
committed by GitHub
parent 8f768f8276
commit cd38cb8290
18 changed files with 373 additions and 27 deletions

View File

@ -11,6 +11,12 @@ import (
"github.com/google/uuid"
)
type TemplateVersionWarning string
const (
TemplateVersionWarningDeprecatedParameters TemplateVersionWarning = "DEPRECATED_PARAMETERS"
)
// TemplateVersion represents a single version of a template.
type TemplateVersion struct {
ID uuid.UUID `json:"id" format:"uuid"`
@ -22,6 +28,8 @@ type TemplateVersion struct {
Job ProvisionerJob `json:"job"`
Readme string `json:"readme"`
CreatedBy User `json:"created_by"`
Warnings []TemplateVersionWarning `json:"warnings,omitempty" enums:"DEPRECATED_PARAMETERS"`
}
type TemplateVersionGitAuth struct {