Can we get a mail from gitlab , If the pipeline started itself?

Viewed 115

We're using gitlab for ci/cd .By using gitlab notification setup , we are getting mails but If the pipeline ends only, mail will triggered the status of the pipeline. Is there any possibility for getting mail when pipeline starts status? and another one thing , by using SMTP ,gitlab.rb , Please any one explain about this. The recipients whoever getting my mail, they need more information regarding the pipeline status. I searched for that , it shows relatedly gitlab.rb and smtp .But I didn't getting clear about that. Please anyone explain about the SMTP .We want the deployment for email notification. Thanks in advance

1 Answers

Call a Web API that sends email (e.g. - mailgun, sendgrid) via curl/wget as the first command in the script: section of the deploy Job within .gitlab-ci.yml

Or, use a CLI tool such as sendmail or ssmtp.

Either option will require configuration in the form of an API token or SMTP credentials.

See an example for using the Mailgun API, here.

Related