You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<p>All functions are loaded by configng’s module loader. They share global state (<code>DESKTOP_*</code> variables, <code>desktops_dir</code>, <code>DISTROID</code>) — call sites must follow the documented order.</p>
<p>Top-level dispatcher. The <code>de=</code>, <code>tier=</code>, <code>arch=</code>, <code>release=</code> arguments are parsed positionally from <code>$@</code>.</p>
3821
+
<p>Top-level dispatcher. The <code>de=</code>, <code>tier=</code>, <code>arch=</code>, <code>release=</code>, <code>mode=</code> arguments are parsed positionally from <code>$@</code>.</p>
<td>Full install pipeline (see <ahref="#lifecycle-install">Lifecycle</a>). Bails out cleanly on <code>pkg_install</code> failure without changing system state.</td>
3834
-
<td><code>de=</code>, <code>tier=</code></td>
3833
+
<td>Full install pipeline (see <ahref="#lifecycle-install">Lifecycle</a>). Bails out cleanly on <code>pkg_install</code> failure without changing system state. With <code>mode=build</code>: skips user detection, group membership, skel propagation, and DM start/autologin — intended for image-build time when no real user exists.</td>
<p>Not called from the desktop install path by default. The <code>armbian-imager</code> AppImage is available via <code>armbian-config --api module_appimage install app=armbian-imager</code> for users who explicitly want it.</p>
<p>The install pipeline in <code>module_desktops install</code> is intentionally linear and idempotent-friendly. <strong>Every step that touches system state is gated on the previous step’s success.</strong></p>
4072
-
<divclass="language-text highlight"><spanclass="filename">Text Only</span><pre><span></span><code><spanid="__span-19-1"><aid="__codelineno-19-1" name="__codelineno-19-1" href="#__codelineno-19-1"></a>1. Validate args de= and tier= both required; tier must be minimal|mid|full
4073
-
</span><spanid="__span-19-2"><aid="__codelineno-19-2" name="__codelineno-19-2" href="#__codelineno-19-2"></a>2. Resolve target user module_desktop_getuser
</span><spanid="__span-19-9"><aid="__codelineno-19-9" name="__codelineno-19-9" href="#__codelineno-19-9"></a>9. Reset ACTUALLY_INSTALLED array used by pkg_install to record new packages
</span><spanid="__span-19-13"><aid="__codelineno-19-13" name="__codelineno-19-13" href="#__codelineno-19-13"></a>12. (Armbian) install plymouth if /etc/apt/sources.list.d/armbian.{list,sources} present
4085
-
</span><spanid="__span-19-14"><aid="__codelineno-19-14" name="__codelineno-19-14" href="#__codelineno-19-14"></a>13. Save install manifest /etc/armbian/desktop/<de>.packages and <de>.tier
</span><spanid="__span-19-17"><aid="__codelineno-19-17" name="__codelineno-19-17" href="#__codelineno-19-17"></a>16. Add user to groups sudo netdev audio video dialout plugdev input bluetooth systemd-journal ssh
</span><spanid="__span-19-20"><aid="__codelineno-19-20" name="__codelineno-19-20" href="#__codelineno-19-20"></a>19. Stop other DMs gdm3/lightdm/sddm one by one
</span><spanid="__span-19-22"><aid="__codelineno-19-22" name="__codelineno-19-22" href="#__codelineno-19-22"></a>21. Switch default.target systemctl set-default graphical.target ONLY if step 20 succeeded
4094
-
</span><spanid="__span-19-23"><aid="__codelineno-19-23" name="__codelineno-19-23" href="#__codelineno-19-23"></a>22. Enable auto-login module_desktops auto de=$de
4072
+
<p>Steps marked with <code>[R]</code> are <strong>runtime-only</strong> — skipped when <code>mode=build</code> is passed (image build time, no real user exists). Steps marked with <code>[B]</code> run in <strong>both</strong> modes.</p>
4073
+
<divclass="language-text highlight"><spanclass="filename">Text Only</span><pre><span></span><code><spanid="__span-19-1"><aid="__codelineno-19-1" name="__codelineno-19-1" href="#__codelineno-19-1"></a> 1. [B] Validate args de= and tier= both required; tier must be minimal|mid|full
4074
+
</span><spanid="__span-19-2"><aid="__codelineno-19-2" name="__codelineno-19-2" href="#__codelineno-19-2"></a> 2. [R] Resolve target user module_desktop_getuser (skipped in mode=build)
</span><spanid="__span-19-10"><aid="__codelineno-19-10" name="__codelineno-19-10" href="#__codelineno-19-10"></a>10. [B] Reset ACTUALLY_INSTALLED array used by pkg_install to record new packages
</span><spanid="__span-19-14"><aid="__codelineno-19-14" name="__codelineno-19-14" href="#__codelineno-19-14"></a>13. [B] (Armbian) install plymouth if /etc/apt/sources.list.d/armbian.{list,sources} present
4087
+
</span><spanid="__span-19-15"><aid="__codelineno-19-15" name="__codelineno-19-15" href="#__codelineno-19-15"></a>14. [B] Save install manifest /etc/armbian/desktop/<de>.packages and <de>.tier
</span><spanid="__span-19-18"><aid="__codelineno-19-18" name="__codelineno-19-18" href="#__codelineno-19-18"></a>17. [R] Add user to groups sudo netdev audio video dialout plugdev input bluetooth systemd-journal ssh
</span><spanid="__span-19-21"><aid="__codelineno-19-21" name="__codelineno-19-21" href="#__codelineno-19-21"></a>20. [R] Stop other DMs gdm3/lightdm/sddm one by one
</span><spanid="__span-19-23"><aid="__codelineno-19-23" name="__codelineno-19-23" href="#__codelineno-19-23"></a>22. [R] Switch default.target systemctl set-default graphical.target ONLY if step 21 succeeded
4096
+
</span><spanid="__span-19-24"><aid="__codelineno-19-24" name="__codelineno-19-24" href="#__codelineno-19-24"></a>23. [R] Enable auto-login module_desktops auto de=$de
4095
4097
</span></code></pre></div>
4096
-
<p>If step 10 or 11 fails, the function returns 1 with no further state changes — the manifest is not written, <code>default.target</code> stays at <code>multi-user</code>, no DM is started. The system is in the same state as if the install had never run.</p>
4098
+
<p><strong><code>mode=build</code></strong> is used by the Armbian build framework at image-creation time. At that point the rootfs has no regular user (armbian-firstrun creates the first user on first boot), and DM/systemd operations make no sense inside a chroot. The packages, branding, manifests, and <code>/etc/skel</code> all land correctly; the first user inherits skel at <code>useradd</code> time and armbian-firstrun manages <code>graphical.target</code>.</p>
4099
+
<p>If step 11 or 12 fails, the function returns 1 with no further state changes — the manifest is not written, <code>default.target</code> stays at <code>multi-user</code>, no DM is started. The system is in the same state as if the install had never run.</p>
0 commit comments