jenkins

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2022 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOrUpdateJob

func CreateOrUpdateJob(options plugininstaller.RawOptions) error

func DeleteJob

func DeleteJob(options plugininstaller.RawOptions) error

func PreInstall

func PreInstall(plugins []string, cascTemplate string) plugininstaller.BaseOperation

func SetJobDefaultConfig

func SetJobDefaultConfig(options plugininstaller.RawOptions) (plugininstaller.RawOptions, error)

SetJobDefaultConfig config default fields for usage

Types

type ImageRepo

type ImageRepo struct {
	URL  string `mapstructure:"url" validate:"url"`
	User string `mapstructure:"user"`
}

type Jenkins

type Jenkins struct {
	URL           string `mapstructure:"url" validate:"required,url"`
	User          string `mapstructure:"user"`
	Namespace     string `mapstructure:"namespace"`
	EnableRestart bool   `mapstructure:"enableRestart"`
}

type JobOptions

type JobOptions struct {
	Jenkins  Jenkins  `mapstructure:"jenkins"`
	SCM      SCM      `mapstructure:"scm"`
	Pipeline Pipeline `mapstructure:"pipeline"`

	// used in package
	BasicAuth   *jenkins.BasicAuth `mapstructure:"basicAuth"`
	ProjectRepo *common.Repo       `mapstructure:"projectRepo"`
	CIConfig    *ci.CIConfig       `mapstructure:"ci"`
	SecretToken string             `mapstructure:"secretToken"`
}

type Pipeline

type Pipeline struct {
	JobName         string    `mapstructure:"jobName" validate:"required"`
	JenkinsfilePath string    `mapstructure:"jenkinsfilePath" validate:"required"`
	ImageRepo       ImageRepo `mapstructure:"imageRepo"`
}

type SCM

type SCM struct {
	ProjectURL    string `mapstructure:"projectURL" validate:"required"`
	ProjectBranch string `mapstructure:"projectBranch"`
}

Jump to

Keyboard shortcuts

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