We need to send a mail when our production deployment is finished.
Our production environment contains 5 servers.
If I add a step to send a mail, it will send it 5 times, once per server.
Thanks for reaching out. Are you using a custom script step to send en email by any chance? If you are, then that’s the reason why you are getting an email per machine.
If you use the built-in email step (see attached screenshot) you should only get 1 email per deployment and not 1 per machine.
You could add a custom script step and scope it to a specific role that only points to one machine. For example you have 5 machines in the environment “Dev” with the role “WebServer”. Have one of those also have the role “ScriptRunner” and then scope the custom script step to the “ScriptRunner” role.
What many users do in this case to avoid having to pick one of their servers as the scriptrunner, is turn the Octopus Server itself into a Tentacle and have that server run all the steps that only need to be executed once.