@subven said in smtp mailer config lost after restore from backup:
@girish AFAIK passwords in environment variables change after restart (from what I remember regarding the LAMP app) so what is the point in hardcoding them into something like a plugin? You could use the variable for SMTP_PASSWORD in your config file though.
Assuming you mean the Cloudron part, the Cloudron environment variables are kept "constant" over the life cycle of an app. Initially, our idea was to change these periodically automatically for security but it seems people put the database values into into other apps which breaks. So, we didn't implement it.
As for putting it in the plugin, the smtp plugin we use reads the password from the database and does not use config.php - https://plugins.trac.wordpress.org/browser/smtp-mailer/trunk/main.php#L725 .