Open the /etc/hosts.allow file in order to add a new entry.
Enter your GoodAccess gateway's Static IP address. Below you will find an example of two permitted IP addresses.
sshd: 18.104.22.168/32, 22.214.171.124/32
Be sure that you've entered the correct IP address to any issues with connectivity and then save the file.
Now let's block access from all other sources apart from the defined ones. To do so, edit the /etc/hosts.deny by adding the following entry and save your changes.
Test the access with and without being connected with the GoodAccess Client App to be sure that the SSH access is protected.
Note: There are several other ways to restrict access to SSH servers like IPTABLES firewall (restrict the access to TCP port 22) or SSH daemon config.