config

package
v0.0.0-...-feeaf7e Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const Name = "uci"

Variables

View Source
var Items = make([]*UciConfigItem, 0)
View Source
var UciDirConfigItem = NewUciConfigItem("UCI_DIR", func() string {
	return path.Join(SystemHomeDir(), fmt.Sprintf(".%s", Name))
})
View Source
var UciServerUrl = NewUciConfigItem("UCI_SERVER_URL", func() string {
	return "http://messaging.uci.127.0.0.1.nip.io"
})

Functions

func Map

func Map() map[string]*UciConfigItem

func SystemHomeDir

func SystemHomeDir() string

func UciConfigPath

func UciConfigPath() string

func UciDir

func UciDir() (string, error)

func UciPipelineDir

func UciPipelineDir(workflowId int64, pipelineId int64, salt string) (string, error)

func UciPipelineWorkspaceDir

func UciPipelineWorkspaceDir(workflowId int64, pipelineId int64, salt string) (string, error)

Types

type DispatchMode

type DispatchMode string
const Docker DispatchMode = "docker"
const DockerInDocker DispatchMode = "docker-in-docker"
const Host DispatchMode = "host"
const RootlessDocker DispatchMode = "rootless-docker"

type UciConfigItem

type UciConfigItem struct {
	Name    string
	Default func() string
}
var UciDispatchModeItem *UciConfigItem = NewUciConfigItem("UCI_DISPATCH_MODE", func() string {
	return string(Host)
})

func NewUciConfigItem

func NewUciConfigItem(name string, d func() string) *UciConfigItem

func (*UciConfigItem) Value

func (u *UciConfigItem) Value() (string, error)

Jump to

Keyboard shortcuts

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