Documentation
¶
Index ¶
- Constants
- func BuildWorkFlowsWrapper(workflows []*github.Workflow) plugininstaller.MutableOperation
- func GetActionState(options plugininstaller.RawOptions) (statemanager.ResourceState, error)
- func GetStaticWorkFlowState(options plugininstaller.RawOptions) (statemanager.ResourceState, error)
- func ProcessAction(act action) plugininstaller.BaseOperation
- func Validate(options plugininstaller.RawOptions) (plugininstaller.RawOptions, error)
- type Build
- type Coverage
- type Docker
- type GithubActionLanguage
- type GithubActionOptions
- func (opts *GithubActionOptions) CheckAddDockerHubToken() bool
- func (opts *GithubActionOptions) Encode() (map[string]interface{}, error)
- func (opts *GithubActionOptions) GetGithubClient() (*github.Client, error)
- func (opts *GithubActionOptions) GetLanguage() string
- func (opts *GithubActionOptions) RenderWorkFlow(content string) (string, error)
- type Image
- type Registry
- type RegistryType
- type Tag
- type Test
Constants ¶
View Source
const ( ActionCreate action = "create" ActionDelete action = "delete" ActionUpdate action = "update" )
View Source
const ( RegistryDockerhub RegistryType = "dockerhub" RegistryHarbor RegistryType = "harbor" CommitMessage = "GitHub Actions workflow, created by DevStream" PRBuilderFileName = "pr-builder.yml" MainBuilderFileName = "main-builder.yml" )
Variables ¶
This section is empty.
Functions ¶
func BuildWorkFlowsWrapper ¶
func BuildWorkFlowsWrapper(workflows []*github.Workflow) plugininstaller.MutableOperation
func GetActionState ¶
func GetActionState(options plugininstaller.RawOptions) (statemanager.ResourceState, error)
func GetStaticWorkFlowState ¶
func GetStaticWorkFlowState(options plugininstaller.RawOptions) (statemanager.ResourceState, error)
func ProcessAction ¶
func ProcessAction(act action) plugininstaller.BaseOperation
ProcessAction config github
func Validate ¶
func Validate(options plugininstaller.RawOptions) (plugininstaller.RawOptions, error)
Types ¶
type GithubActionLanguage ¶
GithubActionLanguage is the language of repo
type GithubActionOptions ¶
type GithubActionOptions struct { Owner string `validate:"required_without=Org"` Org string `validate:"required_without=Owner"` Repo string `validate:"required"` Branch string `validate:"required"` Language *GithubActionLanguage `validate:"required"` // optional Workflows []*github.Workflow Build Build Test *Test Docker *Docker }
GithubActionOptions is the struct for configurations of the plugin.
func NewGithubActionOptions ¶
func NewGithubActionOptions(options plugininstaller.RawOptions) (*GithubActionOptions, error)
func (*GithubActionOptions) CheckAddDockerHubToken ¶ added in v0.9.0
func (opts *GithubActionOptions) CheckAddDockerHubToken() bool
func (*GithubActionOptions) Encode ¶
func (opts *GithubActionOptions) Encode() (map[string]interface{}, error)
func (*GithubActionOptions) GetGithubClient ¶
func (opts *GithubActionOptions) GetGithubClient() (*github.Client, error)
func (*GithubActionOptions) GetLanguage ¶
func (opts *GithubActionOptions) GetLanguage() string
func (*GithubActionOptions) RenderWorkFlow ¶
func (opts *GithubActionOptions) RenderWorkFlow(content string) (string, error)
type Registry ¶
type Registry struct { // only support dockerhub now Type RegistryType Username string Repository string }
type RegistryType ¶
type RegistryType string
Click to show internal directories.
Click to hide internal directories.