Perhaps someone got your smtp password and sent from somewhere else? Perhaps they hacked your server (is it protected by a password and you don’t have fail2ban?). Something like that.
There’s pretty much zero chance that Discourse has anything to do with it.
You should probably set up a new server and migrate discourse there.