Example #1
0
func (e *execError) Details() string {
	out := &bytes.Buffer{}
	fmt.Fprintf(out, "Container: %s\n", e.container)
	fmt.Fprintf(out, "Command: %v\n", e.cmd)
	fmt.Fprintf(out, "Result Code: %d\n", e.rc)
	if len(e.out) > 0 {
		errors.PrintLog(out, "Output", e.out)
	}
	if len(e.err) > 0 {
		errors.PrintLog(out, "Error Output", e.err)
	}
	return out.String()
}
Example #2
0
func (e *runError) Details() string {
	out := &bytes.Buffer{}
	fmt.Fprintf(out, "Image: %s\n", e.config.Image)
	fmt.Fprintf(out, "Entrypoint: %v\n", e.config.Entrypoint)
	fmt.Fprintf(out, "Command: %v\n", e.config.Cmd)
	if len(e.out) > 0 {
		errors.PrintLog(out, "Output", e.out)
	}
	if len(e.err) > 0 {
		errors.PrintLog(out, "Error Output", e.err)
	}
	return out.String()
}