You can access your OData services provided by SAP Gateway through an HTTPS load balancer. This load balancer forwards the requests to SAP Gateway. SAP Gateway then generates absolute URLs in its replies for ATOM Ids as well as media links and the XML base URL. It is possible to have SAP Gateway use the host name and port used in the service request.
On your load balancer you can set HTTP header fields and thus influence the response from SAP Gateway. You simply need to enter host name and port into table HTTPURLLOC.
For more information, see the SAP NetWeaver documentation about URL Generation in an AS-ABAP - Web Dispatcher Configuration.
An SDN article is also available on this topic: https://wiki.sdn.sap.com/wiki/display/BSP/Using%20Proxies