What do I have to do to be able to access my local network over ssh with a dynamic IP address?
Use a dynamic DNS service. This is basically a little script or daemon that calls into a dns server so it gets updated whenever the IP changes. There are a number of providers for this service. For home use or only a few addresses you can use a free service like duck dns. I've used them since dyndns kicked off all their free customers and haven't had any problems. This assumes that you have a server that is publicly available and it is listening on some port (22 by default) for ssh connections. If you don't have the server set up edit your question with the set up you have we we can add more steps.