WF: allow to use multiply slack channels
PRODX-3456
Change-Id: Ia828deb9f8509fa3370d23112618014081f4643b
diff --git a/src/com/mirantis/mk/Workflow.groovy b/src/com/mirantis/mk/Workflow.groovy
index 03a43a6..44203ab 100644
--- a/src/com/mirantis/mk/Workflow.groovy
+++ b/src/com/mirantis/mk/Workflow.groovy
@@ -319,10 +319,12 @@
try {
if (wfPauseStepSlackReportChannel) {
def slack = new com.mirantis.mcp.SlackNotification()
- slack.jobResultNotification('wf_pause_step_before_run',
- wfPauseStepSlackReportChannel,
- env.JOB_NAME, null,
- env.BUILD_URL, 'slack_webhook_url')
+ wfPauseStepSlackReportChannel.split(',').each {
+ slack.jobResultNotification('wf_pause_step_before_run',
+ it.toString(),
+ env.JOB_NAME, null,
+ env.BUILD_URL, 'slack_webhook_url')
+ }
}
timeout(time: wfPauseStepTimeout, unit: 'MINUTES') {
input("Workflow pause requested before run: ${jobName}/${jobDescription}\n" +