How can I enable CORS headers using custom server script?

Since I don’t have direct access to my source code because my app is hosted on frappe cloud, is there anyone with an idea on how to enable CORS headers using custom server script?