How to setup smtp email in production

Yes exactly, according to your version of OpenEDX!

The error seems to be here, it seems like the key LMS_ROOT_URL is undefined or platform_name: lms_url=LMS_ROOT_URL, platform_name=platform_name

First: verify your siteConfiguration in django Admin, see if you have LMS_ROOT_URL
Second: verify you have set ‘LMS_ROOT_URL’ in lms.env.json and cms.env.json, also verify ‘site_name’ and ‘site_domain’

I’m not sure if the configuration variables are case sensitive…anyway, just check if ‘platform_name’ is exactly writen like this