Discourse app.yml doesn't like email password contain "#"

That suggests a double quoting trick may work, eg:

DISCOURSE_SMTP_PASSWORD: "'#1passwordEVAR'"