diff options
author | Valery Piashchynski <[email protected]> | 2021-07-14 20:59:00 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2021-07-14 20:59:00 +0300 |
commit | 7ea227733e0b1fa59021233e6cd0fd06442fbe50 (patch) | |
tree | dcba3e2fddf53898d0f5c82eb128730ab38c723a /plugins/jobs/pipeline/pipeline.go | |
parent | 04fde6d8d1a5a88602f8206e0d2c09c4b8346941 (diff) |
Fix incorrect path in the CI. Implement FromPipeline for the sqs.
Signed-off-by: Valery Piashchynski <[email protected]>
Diffstat (limited to 'plugins/jobs/pipeline/pipeline.go')
-rw-r--r-- | plugins/jobs/pipeline/pipeline.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/plugins/jobs/pipeline/pipeline.go b/plugins/jobs/pipeline/pipeline.go index 90eeb189..2f4671d3 100644 --- a/plugins/jobs/pipeline/pipeline.go +++ b/plugins/jobs/pipeline/pipeline.go @@ -66,6 +66,18 @@ func (p Pipeline) Bool(name string, d bool) bool { return d } +// Map must return nested map value or empty config. +// Here might be sqs attributes or tags for example +func (p Pipeline) Map(name string, out map[string]interface{}) { + if value, ok := p[name]; ok { + if m, ok := value.(map[string]interface{}); ok { + for k, v := range m { + out[k] = v + } + } + } +} + // Priority returns default pipeline priority func (p Pipeline) Priority() int64 { if value, ok := p[priority]; ok { |