Establishing IPSec tunnel between Linux and Fortigate
Here is an example of a tunnel setup beetween Linux and Fortigate. It uses StrongSwan.
This configures the forwarding policy. If you want to access the remote end of the tunnel from the gateway, set up a virtual interface and configure it with an address within the local_subnet.