sudo apt-get install ruby1.8-dev
Reference: https://forum.proxmox.com/threads/proxmox-ve-screen-out-of-range.131297/