How to get SMTP variables into script

I am writing a script to do some testing and I want to send an email within the script. I would like to use the SMTP settings, if they exist, that are contained within the octopus deploy system itself rather than having them as input textboxes in the step itself.

How can I:
A) Get the smtp information from octopus deploy to send the email

  • or -
    B) Send an email within my powershell script with an attachment.


I just found this

Is this still the case?


Thanks for getting in touch! Unfortunately, that is still the case. The SMTP settings aren’t made available to use in scripts, as mentioned in that link.

Sorry it’s not better news. Don’t hesitate to reach out if you have any further questions!

Best regards,