Your database connection strings. IMHO you’ll be connecting to sccjono.com
instead of e.g. localhost
and that will naturally fail when the record is proxied.
Assuming your server IP address ends in 70, it would currently fail with a direct request as well and return a 500 after 120 seconds (which also explains the 524).
Make sure you are using everywhere either localhost or the proper IP address of the server and not any proxied hostnames.