MCPcopy
hub / github.com/argoproj/argo-workflows / GetTerminationGracePeriodDuration

Function GetTerminationGracePeriodDuration

workflow/executor/executor.go:807–813  ·  view source on GitHub ↗

GetTerminationGracePeriodDuration returns the terminationGracePeriodSeconds of podSpec in Time.Duration format

()

Source from the content-addressed store, hash-verified

805
806// GetTerminationGracePeriodDuration returns the terminationGracePeriodSeconds of podSpec in Time.Duration format
807func GetTerminationGracePeriodDuration() time.Duration {
808 x, _ := strconv.ParseInt(os.Getenv(common.EnvVarTerminationGracePeriodSeconds), 10, 64)
809 if x > 0 {
810 return time.Duration(x) * time.Second
811 }
812 return 30 * time.Second
813}
814
815// CaptureScriptResult will add the stdout of a script template as output result
816func (we *WorkflowExecutor) CaptureScriptResult(ctx context.Context) error {

Callers 3

NewEmissaryCommandFunction · 0.92
killContainersMethod · 0.85
KillArtifactSidecarsMethod · 0.85

Calls 1

DurationMethod · 0.45

Tested by

no test coverage detected