Documentation
¶
Index ¶
- Constants
- func AddWegoIgnore(sourceManifest []byte) ([]byte, error)
- func AppAutomationDeployPath(a models.Application) string
- func AppAutomationKustomizePath(a models.Application) string
- func AppAutomationSourcePath(a models.Application) string
- func AppDeployName(a models.Application) string
- func AppToWegoApp(app models.Application) wego.Application
- func AppYamlDir(a models.Application) string
- func AppYamlPath(a models.Application) string
- func ApplicationNameTooLong(name string) bool
- func AutomationUserKustomizePath(clusterName string) string
- func ConstrainResourceName(str string) string
- func CreateKustomize(name, namespace string, resources ...string) types.Kustomization
- func GenerateResourceName(url gitproviders.RepoURL) string
- func GetAppHash(a models.Application) string
- func GetOrCreateKustomize(filename, name, namespace string) (types.Kustomization, error)
- func WegoAppToApp(app wego.Application) (models.Application, error)
- type AutomationGen
- type AutomationGenerator
- type AutomationManifest
- type ConfigMode
- type GeneratedSecretName
- type ResourceKind
- type ResourceRef
- type SourceType
Constants ¶
View Source
const ( MaxKubernetesResourceNameLength = 63 WeGOAppIdentifierLabelKey = "wego.weave.works/app-identifier" )
View Source
const ( ConfigModeClusterOnly ConfigMode = "clusterOnly" ConfigModeUserRepo ConfigMode = "userRepo" ConfigModeExternalRepo ConfigMode = "externalRepo" ResourceKindApplication ResourceKind = "Application" ResourceKindSecret ResourceKind = "Secret" ResourceKindGitRepository ResourceKind = "GitRepository" ResourceKindHelmRepository ResourceKind = "HelmRepository" ResourceKindKustomization ResourceKind = "Kustomization" ResourceKindHelmRelease ResourceKind = "HelmRelease" )
Variables ¶
This section is empty.
Functions ¶
func AddWegoIgnore ¶
func AppAutomationDeployPath ¶
func AppAutomationDeployPath(a models.Application) string
func AppAutomationKustomizePath ¶
func AppAutomationKustomizePath(a models.Application) string
func AppAutomationSourcePath ¶
func AppAutomationSourcePath(a models.Application) string
func AppDeployName ¶
func AppDeployName(a models.Application) string
func AppToWegoApp ¶
func AppToWegoApp(app models.Application) wego.Application
func AppYamlDir ¶
func AppYamlDir(a models.Application) string
func AppYamlPath ¶
func AppYamlPath(a models.Application) string
func ApplicationNameTooLong ¶
func ConstrainResourceName ¶
func CreateKustomize ¶
func CreateKustomize(name, namespace string, resources ...string) types.Kustomization
func GenerateResourceName ¶
func GenerateResourceName(url gitproviders.RepoURL) string
func GetAppHash ¶
func GetAppHash(a models.Application) string
func GetOrCreateKustomize ¶
func GetOrCreateKustomize(filename, name, namespace string) (types.Kustomization, error)
func WegoAppToApp ¶
func WegoAppToApp(app wego.Application) (models.Application, error)
Types ¶
type AutomationGen ¶
type AutomationGen struct { GitProvider gitproviders.GitProvider Flux flux.Flux Logger logger.Logger }
func (*AutomationGen) GenerateAutomation ¶
func (a *AutomationGen) GenerateAutomation(ctx context.Context, app models.Application, clusterName string) ([]AutomationManifest, error)
type AutomationGenerator ¶
type AutomationGenerator interface {
GenerateAutomation(ctx context.Context, app models.Application, clusterName string) ([]AutomationManifest, error)
}
func NewAutomationGenerator ¶
func NewAutomationGenerator(gp gitproviders.GitProvider, flux flux.Flux, logger logger.Logger) AutomationGenerator
type AutomationManifest ¶
type ConfigMode ¶
type ConfigMode string
type GeneratedSecretName ¶
type GeneratedSecretName string
func CreateRepoSecretName ¶
func CreateRepoSecretName(gitSourceURL gitproviders.RepoURL) GeneratedSecretName
func (GeneratedSecretName) String ¶
func (s GeneratedSecretName) String() string
type ResourceKind ¶
type ResourceKind string
func DeployKind ¶
func DeployKind(a models.Application) ResourceKind
func SourceKind ¶
func SourceKind(a models.Application) ResourceKind
func (ResourceKind) ToGVR ¶
func (rk ResourceKind) ToGVR() (schema.GroupVersionResource, error)
type ResourceRef ¶
type ResourceRef struct { Kind ResourceKind Name string RepositoryPath string }
type SourceType ¶
type SourceType string
Click to show internal directories.
Click to hide internal directories.