Configure Wake-on-LAN
Configuring Wake-on-LAN is a simple process on Alpine Linux. First, check if your network card supports Wake-on-LAN (WOL):
# apk add ethtool # ethtool eth0 | grep -i wake Supports Wake-on: pumbg Wake-on: d
Supports Wake-on: pumbg means that WOL is supported, Wake-on: d means that it is currently disabled. To enable it, edit /etc/network/interfaces as follows:
auto eth0 pre-up /usr/sbin/ethtool -s eth0 wol g
Reboot, and you should now be able to wake your machine from LAN. You can check if it is really enabled like so:
# ethtool eth0 | grep -i wake Supports Wake-on: pumbg Wake-on: g
Wake-on: g means that it is now enabled.
There are many tools that allow you to wake up the machine now that WOL is supported; https://github.com/sabhiram/go-wol is an excellent one.