Exposed build output to api

This commit is contained in:
2023-02-24 23:59:02 -07:00
parent 712a7b1429
commit 7e7c49c2e7
3 changed files with 19 additions and 7 deletions
+2 -1
View File
@@ -323,7 +323,7 @@ WHERE id=$5;`
func (db *Database) GetRunsForPipeline(pipelineId uuid.UUID) ([]Run, error) {
query := `
SELECT id, in_progress, result, stdout, stderr
SELECT id, in_progress, result, build_output, stdout, stderr
FROM runs
WHERE pipeline=$1;`
@@ -342,6 +342,7 @@ WHERE pipeline=$1;`
&idStr,
&run.InProgress,
&run.Result,
&run.BuildOutput,
&run.Stdout,
&run.Stderr,
); err != nil {
+7 -6
View File
@@ -54,12 +54,13 @@ type Webhook struct {
}
type Run struct {
Id uuid.UUID
Pipeline uuid.UUID
InProgress bool
Result *int64
Stdout []byte
Stderr []byte
Id uuid.UUID
Pipeline uuid.UUID
InProgress bool
Result *int64
BuildOutput []byte
Stdout []byte
Stderr []byte
}
type CommandExecution struct {