Add configurable layers in manifest events

Signed-off-by: Andrew Leung <anwleung@gmail.com>
This commit is contained in:
Andrew Leung 2018-06-27 08:47:40 -07:00
parent 749f6afb45
commit 276fdce3d9
9 changed files with 66 additions and 18 deletions

View file

@ -544,6 +544,8 @@ func (auth Auth) MarshalYAML() (interface{}, error) {
// Notifications configures multiple http endpoints.
type Notifications struct {
// EventConfig is the configuration for the event format that is sent to each Endpoint.
EventConfig Events `yaml:"events,omitempty"`
// Endpoints is a list of http configurations for endpoints that
// respond to webhook notifications. In the future, we may allow other
// kinds of endpoints, such as external queues.
@ -564,6 +566,11 @@ type Endpoint struct {
Ignore Ignore `yaml:"ignore"` // ignore event types
}
// Events configures notification events.
type Events struct {
ManifestLayers bool `yaml:"manifestlayers"` // include layer data in manifest events
}
//Ignore configures mediaTypes and actions of the event, that it won't be propagated
type Ignore struct {
MediaTypes []string `yaml:"mediatypes"` // target media types to ignore