How to set stactic IP?

Yunohost have DHCP Ip configuration, due to which it takes different Ip every time router restarts. This lead to a problem of port forwarding ever time different Ip is taken by yunohost.
How can I configure yunohost to have static Ip ?

You can manually edit the /etc/network/interfaces file.

And if you have UPnP working, it does not matter if the IP changes,
since the server asks for port openning every few minutes (thus update
the local IP address)

This link is very helpful.
Thank you