-
Notifications
You must be signed in to change notification settings - Fork 7
/
types.go
37 lines (32 loc) · 945 Bytes
/
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
package kubernetes
// PodEvent represents Pod termination event
type PodEvent struct {
Namespace string `json:"namespace"`
Name string `json:"name"`
State string `json:"state"`
Reason string `json:"reason"`
Message string `json:"message"`
Containers []Container `json:"containers"`
ArtifactID string `json:"artifactId"`
}
type Container struct {
Name string `json:"name"`
State string `json:"state"`
Reason string `json:"reason"`
Message string `json:"message"`
Ready bool `json:"ready"`
RestartCount int32 `json:"restartCount"`
}
type Log struct {
Level string
Message string
}
// NotifyFunc represents callback function for Pod event
type NotifyFunc = func(event *PodEvent) error
//type ReleaseState string
//
//const (
// Released ReleaseState = "released"
// Deployed ReleaseState = "deployed"
// Failed ReleaseState = "failed"
//)