I can't locate the specific example for hairpin. But if you configure nat-dst from your trust to untrust zone for the server. Then simply add source translation to the interface address on the advanced tab of the policy where the nat-dst is configured.
https://kb.juniper.net/InfoCenter/index?page=content&id=KB12631