If you are having problems creating a working network keyfile or importing the keyfile, this alternate method might work for you. It could also be that you have some other problem so this is not a "cure-all" for your wifi/network issues.
This is not the same access as using the ssh addon. The connection to the host happens on port 22222 and requires that you import an authorized_keys file to your system as described here: https://developers.home-assistant.io/docs/en/hassio_debugging.html
Or, you could connect a keyboard and monitor to your device running HassOS and connect to the host that way.