gitops

package module
v0.0.0-...-6682ef1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 18, 2022 License: Apache-2.0 Imports: 20 Imported by: 0

README

AppStudio Application GitOps library

A library to generate gitops resources for AppStudio Application and its Components.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DetermineBuildExecution

func DetermineBuildExecution(component componentv1alpha1.Component, params []tektonapi.Param, workspaceSubPath string) tektonapi.PipelineRunSpec

DetermineBuildExecution returns the pipelineRun spec that would be used in webhooks-triggered pipelineRuns as well as user-triggered PipelineRuns

func Generate

func Generate(fs afero.Fs, outputFolder string, component appstudiov1alpha1.Component) error

Generate takes in a given Component CR and spits out a deployment, service, and route file to disk

func GenerateBuild

func GenerateBuild(fs afero.Fs, outputFolder string, component componentv1alpha1.Component) error

func GenerateBuildWebhookRoute

func GenerateBuildWebhookRoute(component componentv1alpha1.Component) routev1.Route

GenerateBuildWebhookRoute returns the Route resource that would enable ingress traffic into the webhook endpoint ( aka EventListener) TODO: This needs to be secure.

func GenerateCommonStorage

func GenerateCommonStorage(component componentv1alpha1.Component, name string) corev1.PersistentVolumeClaim

GenerateCommonStorage returns the PVC that would be created per namespace for user-triggered and webhook-triggered Tekton workspaces.

func GenerateEventListener

func GenerateEventListener(component componentv1alpha1.Component, triggerTemplate triggersapi.TriggerTemplate) triggersapi.EventListener

The GenerateEventListener is responsible for defining how to "parse" the incoming event ( "github-push ") and create the resultant PipelineRun ( defined as a TriggerTemplate ). The reconciler for EventListeners create a Service, which when exposed enables ingress traffic from Github events.

func GenerateInitialBuildPipelineRun

func GenerateInitialBuildPipelineRun(component componentv1alpha1.Component) tektonapi.PipelineRun

GenerateInitialBuildPipelineRun generates pipeline run for initial build of the component.

func GenerateTriggerTemplate

func GenerateTriggerTemplate(component componentv1alpha1.Component) (*triggersapi.TriggerTemplate, error)

GenerateTriggerTemplate generates the TriggerTemplate resources which defines how a webhook-based trigger event would be handled - In this case, a PipelineRun to build an image would be created.

Types

This section is empty.

Directories

Path Synopsis
From https://github.com/redhat-developer/kam/tree/master/pkg/pipelines/yaml
From https://github.com/redhat-developer/kam/tree/master/pkg/pipelines/yaml

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL