--- /home/mtrudel/console-setup.postinst.old 2017-08-22 10:07:14.122286492 -0400
+++ debian/console-setup.postinst 2017-08-22 10:06:49.866774834 -0400
@@ -135,6 +135,11 @@
# setting the keymap breaks with plymouth in raw mode, and setting the
# font will currently also break if on vgacon
:
+elif [ -d /run/systemd/sessions ] && \
+ loginctl show-session $XDG_SESSION_ID | grep Type= | grep -qv Type=tty; then
+ # If we're on systemd and the current session isn't a TTY, do nothing
+ # rather than risking to break the session.
+ :
elif [ -d /lib/debian-installer ] || \
expr "$(fgconsole 2>/dev/null || true)" : '[1-6]$' >/dev/null; then
setupcon --force >/dev/null 2>/dev/null || true