When I use an external monitor the laptop does not automatically suspend when I close the lid. Instead the external monitor is then still in use.
I want to configure ubuntu in such a way that the laptop always suspends when I close the lid. Regardless of whether I use an external monitor or not.
I read on logind.conf: If the system is inserted in a docking station, or if more than one display is connected, the action specified by HandleLidSwitchDocked= occurs.
But setting it to suspend didn't work for me.