summary refs log tree commit diff
diff options
context:
space:
mode:
authorworldofpeace <worldofpeace@protonmail.ch>2019-10-05 11:34:27 +0000
committerGitHub <noreply@github.com>2019-10-05 11:34:27 +0000
commit789fcebdaba6e5b51bdd021aac4ec1847214a714 (patch)
tree326bd97f79b0ede8c30e752df7ec9ea0b2fefb16
parent6fad65d5a08e47d08897e8dcadfc1f70b34702c9 (diff)
parent159b12bee7a9b30b0cfe25f53efcc443a130313d (diff)
downloadnixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar.gz
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar.bz2
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar.lz
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar.xz
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.tar.zst
nixpkgs-789fcebdaba6e5b51bdd021aac4ec1847214a714.zip
Merge pull request #46997 from worldofpeace/installer-autorun
installer: autorun xserver in graphical media
-rw-r--r--nixos/doc/manual/release-notes/rl-2003.xml8
-rw-r--r--nixos/modules/installer/cd-dvd/installation-cd-graphical-base.nix3
-rw-r--r--nixos/modules/installer/cd-dvd/iso-image.nix8
3 files changed, 16 insertions, 3 deletions
diff --git a/nixos/doc/manual/release-notes/rl-2003.xml b/nixos/doc/manual/release-notes/rl-2003.xml
index 6de0214b1fb..bdf56acd545 100644
--- a/nixos/doc/manual/release-notes/rl-2003.xml
+++ b/nixos/doc/manual/release-notes/rl-2003.xml
@@ -28,6 +28,14 @@
      Postgresql for NixOS service now defaults to v11.
     </para>
    </listitem>
+   <listitem>
+    <para>
+     The graphical installer image starts the graphical session automatically.
+     Before you'd be greeted by a tty and asked to enter <command>systemctl start display-manager</command>.
+     It is now possible to disable the display-manager from running by selecting the <literal>Disable display-manager</literal>
+     quirk in the boot menu.
+    </para>
+   </listitem>
   </itemizedlist>
  </section>
 
diff --git a/nixos/modules/installer/cd-dvd/installation-cd-graphical-base.nix b/nixos/modules/installer/cd-dvd/installation-cd-graphical-base.nix
index 1578e1547bc..719ba5ffb12 100644
--- a/nixos/modules/installer/cd-dvd/installation-cd-graphical-base.nix
+++ b/nixos/modules/installer/cd-dvd/installation-cd-graphical-base.nix
@@ -25,9 +25,6 @@ with lib;
   services.xserver = {
     enable = true;
 
-    # Don't start the X server by default.
-    autorun = mkForce false;
-
     # Automatically login as nixos.
     displayManager.slim = {
       enable = true;
diff --git a/nixos/modules/installer/cd-dvd/iso-image.nix b/nixos/modules/installer/cd-dvd/iso-image.nix
index 6595d0f30f9..009f1e2c543 100644
--- a/nixos/modules/installer/cd-dvd/iso-image.nix
+++ b/nixos/modules/installer/cd-dvd/iso-image.nix
@@ -290,6 +290,14 @@ let
         ${buildMenuAdditionalParamsGrub2 config "video=1920x1080@60"}
       }
 
+      # If we boot into a graphical environment where X is autoran
+      # and always crashes, it makes the media unusable. Allow the user
+      # to disable this.
+      submenu "Disable display-manager" --class quirk-disable-displaymanager {
+        ${grubMenuCfg}
+        ${buildMenuAdditionalParamsGrub2 config "systemd.mask=display-manager.service"}
+      }
+
       # Some laptop and convertibles have the panel installed in an
       # inconvenient way, rotated away from the keyboard.
       # Those entries makes it easier to use the installer.