Versions in this module Expand all Collapse all v1 v1.0.1 Aug 15, 2024 Changes in this version + const EncryptedValueMinLen + const EnvActionParamPrefix + const EnvCollectorAddr + const EnvContextDir + const EnvDefaultShell + const EnvDefaultTimezone + const EnvDiceIsEdge + const EnvDiceOpenapiAddr + const EnvDiceOpenapiPublicUrl + const EnvEnablePushLog2Collector + const EnvFileStreamTimeoutSec + const EnvMaxCacheFileMB + const EnvMetaFile + const EnvPrefix + const EnvStdErrRegexpList + const EnvSuffixAddr + const EnvSuffixPublicURL + const EnvTaskLogID + const EnvUploadDir + const EnvWorkDir + const MetadataTypeDiceFile + const TagDiceOrgID + const TagDiceOrgName + type Agent struct + Arg *AgentArg + Cancel context.CancelFunc + Ctx context.Context + EasyUse EasyUse + Errs []error + ExitCode int + FWLock sync.Mutex + FileWatcher *filewatch.Watcher + LockPushedMetaFileMap sync.RWMutex + MaxCacheFileSizeMB datasize.ByteSize + PushedMetaFileMap map[string]map[string]struct{} + StdErrRegexpList []*regexp.Regexp + TextBlackList []string + func (agent *Agent) AppendError(err error) + func (agent *Agent) Callback() + func (agent *Agent) CheckForBreakpointOnFailure(breakPointFile string) + func (agent *Agent) Execute(r io.Reader) + func (agent *Agent) Exit() + func (agent *Agent) ListenSignal() + func (agent *Agent) MergeErrors() taskerror.OrderedErrors + func (agent *Agent) PreStop() + func (agent *Agent) SetCallbackReporter() + func (agent *Agent) SetTokenForBootstrap() error + func (agent *Agent) Teardown(exitCode ...int) + type AgentArg struct + Commands interface{} + Context spec.PipelineTaskContext + DebugOnFailure bool + DebugTimeout *time.Duration + EncryptSecretKeys []string + PipelineID uint64 + PipelineTaskID uint64 + PrivateEnvs map[string]string + PullBootstrapInfo bool + Shell string + ShellArgs []string + func NewAgentArgForPull(pipelineID, pipelineTaskID uint64) *AgentArg + type Callback apistructs.ActionCallback + func (c *Callback) AppendMetadataFields(fields []*metadata.MetadataField) + func (c *Callback) HandleMetaFile(b []byte) error + type CallbackReporter interface + CallbackToPipelinePlatform func(cbReq apistructs.PipelineCallbackRequest) error + GetBootstrapInfo func(pipelineID, taskID uint64) (apistructs.PipelineTaskGetBootstrapInfoResponse, error) + GetCmsFile func(uuid string, absPath string) error + PushCollectorLog func(logLines *[]apistructs.LogPushLine) error + SetCollectorAddress func(address string) + SetOpenApiToken func(token string) + UploadFile func(pipelineID, taskID uint64, file *os.File) (*pb.FileUploadResponse, error) + type CenterCallbackReporter struct + CollectorAddr string + FileStreamTimeoutSec time.Duration + OpenAPIAddr string + OpenAPIToken string + TokenForBootstrap string + func (cr *CenterCallbackReporter) CallbackToPipelinePlatform(cbReq apistructs.PipelineCallbackRequest) error + func (cr *CenterCallbackReporter) GetBootstrapInfo(pipelineID, taskID uint64) (apistructs.PipelineTaskGetBootstrapInfoResponse, error) + func (cr *CenterCallbackReporter) GetCmsFile(uuid string, absPath string) error + func (cr *CenterCallbackReporter) PushCollectorLog(logLines *[]apistructs.LogPushLine) error + func (cr *CenterCallbackReporter) SetCollectorAddress(address string) + func (cr *CenterCallbackReporter) SetOpenApiToken(token string) + func (cr *CenterCallbackReporter) UploadFile(pipelineID, taskID uint64, file *os.File) (*pb.FileUploadResponse, error) + type EasyUse struct + CollectorAddr string + CommandScript string + ContainerContext string + ContainerMetaFile string + ContainerTempTarUploadDir string + ContainerUploadDir string + ContainerWd string + EnablePushLog2Collector bool + FileStreamTimeoutSec time.Duration + FlagEndLineForTail string + IsEdgeCluster bool + IsEdgePipeline bool + MachineStat taskinspect.PipelineTaskMachineStat + OpenAPIAddr string + OpenAPIToken string + PipelineAddr string + RunMultiStderr *os.File + RunMultiStderrFilePath string + RunMultiStdout *os.File + RunMultiStdoutFilePath string + RunProcess *os.Process + RunScript string + TaskLogID string + TokenForBootstrap string + type EdgeCallbackReporter struct + CollectorAddr string + FileStreamTimeoutSec time.Duration + OpenAPIToken string + PipelineAddr string + TokenForBootstrap string + func (er *EdgeCallbackReporter) CallbackToPipelinePlatform(cbReq apistructs.PipelineCallbackRequest) error + func (er *EdgeCallbackReporter) GetBootstrapInfo(pipelineID, taskID uint64) (apistructs.PipelineTaskGetBootstrapInfoResponse, error) + func (er *EdgeCallbackReporter) GetCmsFile(uuid string, absPath string) error + func (er *EdgeCallbackReporter) PushCollectorLog(logLines *[]apistructs.LogPushLine) error + func (er *EdgeCallbackReporter) SetCollectorAddress(address string) + func (er *EdgeCallbackReporter) SetOpenApiToken(token string) + func (er *EdgeCallbackReporter) UploadFile(pipelineID, taskID uint64, file *os.File) (*pb.FileUploadResponse, error) + type RunningEnvironment struct + HostIP string