-
Notifications
You must be signed in to change notification settings - Fork 88
/
types.go
106 lines (91 loc) · 3.74 KB
/
types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
package types
import (
"time"
downstreamtypes "github.com/replicatedhq/kots/pkg/api/downstream/types"
versiontypes "github.com/replicatedhq/kots/pkg/api/version/types"
apptypes "github.com/replicatedhq/kots/pkg/app/types"
appstatetypes "github.com/replicatedhq/kots/pkg/appstate/types"
)
type ListAppsResponse struct {
Apps []ResponseApp `json:"apps"`
}
type ListAppsHelmResponse struct {
Apps []HelmResponseApp `json:"apps"`
}
type AppStatusResponse struct {
AppStatus *appstatetypes.AppStatus `json:"appstatus"`
}
type ResponseApp struct {
ID string `json:"id"`
Slug string `json:"slug"`
Name string `json:"name"`
IsAirgap bool `json:"isAirgap"`
CurrentSequence int64 `json:"currentSequence"`
UpstreamURI string `json:"upstreamUri"`
IconURI string `json:"iconUri"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt *time.Time `json:"updatedAt"`
LastUpdateCheckAt *time.Time `json:"lastUpdateCheckAt"`
HasPreflight bool `json:"hasPreflight"`
IsConfigurable bool `json:"isConfigurable"`
UpdateCheckerSpec string `json:"updateCheckerSpec"`
AutoDeploy apptypes.AutoDeploy `json:"autoDeploy"`
Namespace string `json:"namespace"`
IsGitOpsSupported bool `json:"isGitOpsSupported"`
IsIdentityServiceSupported bool `json:"isIdentityServiceSupported"`
IsAppIdentityServiceSupported bool `json:"isAppIdentityServiceSupported"`
IsGeoaxisSupported bool `json:"isGeoaxisSupported"`
IsSemverRequired bool `json:"isSemverRequired"`
IsSupportBundleUploadSupported bool `json:"isSupportBundleUploadSupported"`
AllowRollback bool `json:"allowRollback"`
AllowSnapshots bool `json:"allowSnapshots"`
TargetKotsVersion string `json:"targetKotsVersion"`
LicenseType string `json:"licenseType"`
Downstream ResponseDownstream `json:"downstream"`
}
type Credentials struct {
Username string `json:"username"`
Password string `json:"password"`
}
type HelmResponseApp struct {
ResponseApp
ChartPath string `json:"chartPath,omitempty"`
Credentials Credentials `json:"credentials"`
}
type ResponseDownstream struct {
Name string `json:"name"`
Links []versiontypes.RealizedLink `json:"links"`
CurrentVersion *downstreamtypes.DownstreamVersion `json:"currentVersion"`
PendingVersions []*downstreamtypes.DownstreamVersion `json:"pendingVersions"`
PastVersions []*downstreamtypes.DownstreamVersion `json:"pastVersions"`
GitOps ResponseGitOps `json:"gitops"`
Cluster ResponseCluster `json:"cluster"`
}
type ResponseGitOps struct {
Enabled bool `json:"enabled"`
Provider string `json:"provider"`
Uri string `json:"uri"`
Hostname string `json:"hostname"`
HTTPPort string `json:"httpPort"`
SSHPort string `json:"sshPort"`
Path string `json:"path"`
Branch string `json:"branch"`
Format string `json:"format"`
Action string `json:"action"`
DeployKey string `json:"deployKey"`
IsConnected bool `json:"isConnected"`
}
type ResponseCluster struct {
ID string `json:"id"`
Slug string `json:"slug"`
}
type GetPendingAppResponse struct {
App ResponsePendingApp `json:"app"`
}
type ResponsePendingApp struct {
ID string `json:"id"`
Slug string `json:"slug"`
Name string `json:"name"`
LicenseData string `json:"licenseData"`
NeedsRegistry bool `json:"needsRegistry"`
}