SuperUser headless Debian

Basically, I suspected that disabling the desktop environment on a full Debian install would involve some combination of editing an array of config files, disabling systemd services, and possibly uninstalling certain packages…

I was happily mistaken!

To disable the desktop environment autoload on boot, run the following:

systemctl set-default multi-user.target

Simply run startx after login to start the GUI, if desired.

To re-enable (but why would you?):

systemctl set-default graphical.target

EOF