github.com/giantswarm/apiextensions/v6@v6.6.0/pkg/crd/types.go (about)

     1  package crd
     2  
     3  import (
     4  	"github.com/google/go-github/v39/github"
     5  	v1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
     6  )
     7  
     8  type Patch func(provider string, crd *v1.CustomResourceDefinition)
     9  
    10  type Renderer struct {
    11  	GithubClient *github.Client
    12  
    13  	LocalCRDDirectory string
    14  	OutputDirectory   string
    15  
    16  	Patches map[string]Patch
    17  
    18  	UpstreamAssets     []ReleaseAssetFileDefinition
    19  	RemoteRepositories []RemoteRepositoryDefinition
    20  }
    21  
    22  type ReleaseAssetFileDefinition struct {
    23  	Files    []string
    24  	Owner    string
    25  	Provider string
    26  	Repo     string
    27  	Version  string
    28  }
    29  
    30  type RemoteRepositoryDefinition struct {
    31  	Path      string // path to CRDs in repo, usually "config/crd"
    32  	Owner     string // repo owner
    33  	Provider  string // provider the CRD should be added to in helm charts
    34  	Name      string // name of repo
    35  	Reference string // tag or branch of repo to list files from
    36  }