The 'autossh' class configures the autossh environment, installs the required package support, and configures the global ssh options to be applied to ssh sessions. I've encrypted the private key using eyaml and find this a convenient approach but that does depend on having hiera configured correctly. The port will be accessible on your local machine, but will be automatically forwarded to the remote machine so it appears as if youre remote service (MySQL in. Management of the private key is left to you as care needs to be taken to ensure this private key is adequately protected. I'm gradually adding more functionality here to support customisation of the ssh parameters to watch this space as the module develops. The 'autossh' service provides a reliability and monitoring capability for the ssh tunnels, this includes monitoring the link via a separate 'monitoring ports' if configured and automatically restarting the ssh session if it fails due to an abnormal termination or error detected on the monitoring port.