zotregistry.io/zot@v1.4.4-0.20231124084042-02a8ed785457/pkg/extensions/config/sync/config.go (about)

     1  package sync
     2  
     3  import (
     4  	"time"
     5  )
     6  
     7  // key is registry address.
     8  type CredentialsFile map[string]Credentials
     9  
    10  type Credentials struct {
    11  	Username string
    12  	Password string
    13  }
    14  
    15  type Config struct {
    16  	Enable          *bool
    17  	CredentialsFile string
    18  	Registries      []RegistryConfig
    19  }
    20  
    21  type RegistryConfig struct {
    22  	URLs         []string
    23  	PollInterval time.Duration
    24  	Content      []Content
    25  	TLSVerify    *bool
    26  	OnDemand     bool
    27  	CertDir      string
    28  	MaxRetries   *int
    29  	RetryDelay   *time.Duration
    30  	OnlySigned   *bool
    31  }
    32  
    33  type Content struct {
    34  	Prefix      string
    35  	Tags        *Tags
    36  	Destination string `mapstructure:",omitempty"`
    37  	StripPrefix bool
    38  }
    39  
    40  type Tags struct {
    41  	Regex  *string
    42  	Semver *bool
    43  }