map for storing tags
parent
8276338271
commit
3b65c27f98
|
@ -20,8 +20,12 @@ type TrackedImage struct {
|
|||
Namespace string
|
||||
Secrets []string
|
||||
Meta map[string]string // metadata supplied by providers
|
||||
// a list of pre-release tags, ie: 1.0.0-dev, 1.5.0-prod get translated into
|
||||
// dev, prod
|
||||
// SemverPreReleaseTags []string
|
||||
SemverPreReleaseTags map[string]string
|
||||
}
|
||||
|
||||
func (i TrackedImage) String() string {
|
||||
return fmt.Sprintf("namespace:%s,image:%s,provider:%s,trigger:%s,sched:%s,secrets:%s", i.Namespace, i.Image.Repository(), i.Provider, i.Trigger, i.PollSchedule, i.Secrets)
|
||||
return fmt.Sprintf("namespace:%s,image:%s:%s,provider:%s,trigger:%s,sched:%s,secrets:%s,semver:%v", i.Namespace, i.Image.Repository(), i.Image.Tag(), i.Provider, i.Trigger, i.PollSchedule, i.Secrets, i.SemverPreReleaseTags)
|
||||
}
|
||||
|
|
|
@ -88,11 +88,12 @@ func GetTrackedImage(i string) *types.TrackedImage {
|
|||
panic(err)
|
||||
}
|
||||
return &types.TrackedImage{
|
||||
Image: ref,
|
||||
PollSchedule: "",
|
||||
Trigger: types.TriggerTypeDefault,
|
||||
Provider: "",
|
||||
Namespace: "",
|
||||
Meta: make(map[string]string),
|
||||
Image: ref,
|
||||
PollSchedule: "",
|
||||
Trigger: types.TriggerTypeDefault,
|
||||
Provider: "",
|
||||
Namespace: "",
|
||||
Meta: make(map[string]string),
|
||||
SemverPreReleaseTags: make(map[string]string),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue