KDE Neon OEM mode
Closed, ResolvedPublic

Description

Let's say we want to ship a device with Neon installed. There's some actions that will have to be performed on the first run such as:

  • creation of the user (and its home directory, possibly encrypted)
  • configure few things of the experience such as keyboard layout or hostname

I've been reported that this could be done using Calamares, it can be considered:
https://github.com/calamares/calamares-debian
https://github.com/netrunner-odroid/c1-calamares-core/blob/master/etc/calamares/settings.conf#L32

A good outcome of this task could be an iso that can easily be installed on a system without any of these questions answered.


Ubiquity T4783#69375

Issues

  • Continue button in OEM mode is enabled during final stage (would crash if clicked)
  • Needs slideshow set up and/or fixed for OEM
  • OEM Window not centered on screen

TODO

  • add kwin window rule for system conf
    • center window
    • disable close button
  • change window frame to not include mini and maximize (so oem window can't be accidently minimized)
  • fix enabled continue button (happens because slideshow is being removed when installing the oem template)
  • fix autologin retention (this seems to be caused by sddm.conf not being deleted by bin/ubiquity where it has similar code for kdm/gdm etc.)
  • fix slideshow and coordinate with jens if we want something special other than the static image we use ordinarily
  • fix left hand sidebar missing version data at the top ... only says "neon"
  • closing the window presently ends oem mode as though it was a fully configured system. either prevent closing in any form or fashion or fix the return value so oem mode doesn't end

Calamares

Stuck in limbo T3206

apol created this task.Nov 30 2016, 6:28 PM
apol assigned this task to sitter.Nov 30 2016, 11:14 PM
sitter added a comment.EditedDec 1 2016, 12:32 PM

works almost with ubiquity

http://askubuntu.com/questions/36671/how-do-i-pre-install-ubuntu-for-someone-oem-install

  • start in OEM mode (e.g. oem-config/enable=true in grub cmdline of ISO)
  • install
  • reboot
  • in installed system sudo apt install oem-config oem-config-kde (probably not working out of the box because of T2853)
  • at this point one could do additional modifications
  • sudo oem-config-prepare will put the system into deployment mode
  • reboot
  • oem-config-kde is actually starting now and allowing the configuration of the system
    • has a bug with continue button enabled on last screen
    • we do not have a slideshow here, so last screen is blank background
  • system should auto reboot
  • [BUG] sddm shits its pants because autologin is still set to the temporary OEM user which was removed by oem-config. supposedly oem-config or casper also needs to un-mangle sddm.conf
sitter moved this task from Backlog to Discussing on the Neon board.Dec 1 2016, 1:18 PM

Discussed on telegram. Calamares would be the more reasonable software to use as the python-kde code is in a bad state and Qt4 and baldy integrated. Calamares does have inferior OEM support and user home encryption for OEM isn't a thing apparently (that's only nice-to-have IMO though).

Biggest problem with calamares is that using it is blocked by T3206 which hasn't even been started. Given the importance of the installer, from T3206 being implemented to us actually wanting to use it in a device we'd want to have at least a month of implicit QA through user adoption (i.e. having regular neon ISOs roll with calamares only). Doing so before then only calls for problems as getting updates onto devices is hard or even impossible.

apol added a comment.Dec 12 2016, 11:12 PM

Or maybe it just is easier to do with ubiquity? I feel like this could drag forever...

Seeing as calamares has been drag on for 11 months, I am guessing the chances of it getting dragged on forever are fairly good

Assuming we fix the continue button bug and give it a slideshow, ubiquity should do nicely as well. We'd have to keep our fingers crossed that it doesn't break.

sitter updated the task description. (Show Details)Dec 13 2016, 8:44 AM

Unless there are objections by Friday I'll work on OEM mode fixes next week.

sitter updated the task description. (Show Details)Dec 16 2016, 4:12 PM
sitter triaged this task as Normal priority.Dec 19 2016, 2:24 PM
sitter updated the task description. (Show Details)
sitter moved this task from Discussing to Doing on the Neon board.
sitter updated the task description. (Show Details)Dec 21 2016, 1:42 PM

So, I have most issues covered now. Jens and I refined the sidebar a bit so it doesn't look so shitty.

  • broken continue button is caused by lack of slideshow in oem install, either install manually in oem session or I think I have a fix which should prevent the slideshow from disappearing
  • kwin rules need probably manual creation. I may be able to dump a sane config in place via the oem configuration UI that comes up when the user starts the system but I am not sure that will work reliably
  • mini/maximize needs a decoration setting via systemsettings as I cannot make windowflags do the job. same caveat as with window rules applies
  • Jens wanted to have a more proper welcome screen, alas, I think we don't want to spend the necesary amount of engineering on this (needs l10n set up for python bits, which already has l10n from ubuntu...)
  • autologin retention is weird and I am not sure how this even works for ubuntu TBH, there's casper which creates the original autologin but if that applied it would twiddle the existing autologin to login the configured user instead. there's also code in share/ubiquity which would move /etc/foodm.conf.oem over /etc/foodm.conf, what purpose that serves or where foodm.conf.oem comes from is not clear though. chances are the OEM session should simply have an empty /etc/sddm.conf.oem and ubiquity needs patching to support sddm.conf as a name and then sddm.conf gets wiped upon OEMing. whether or not that is appropriate is another question (e.g. if sddm.conf is installed by sddm proper then overwriting it thusly would cause a dpkg diff conflict moving forward)
  • Jens wants to do some slideshowing, which is kinda hindered by not having any l10n infrastructure set up, as a stop gap a more manual approach may be employed.
  • going to start landing the ubiquity changes as they need some additional QA what with being installer changes and all

Overall I think the OEM experience is really good and more or less snazzy looking.

First part here https://code.launchpad.net/~apachelogger/ubiquity-neon/icantwritetotrunk/+merge/313754

It's probably worthwhile to look into building the oem kwin configs through the scripts somehow as the actual OEM systems may be installed by a human, so the less fiddling the better.

sitter updated the task description. (Show Details)Jan 10 2017, 1:41 PM
sitter moved this task from Doing to Review on the Neon board.Jan 11 2017, 11:06 AM

Development ISOs as of today should have a fully working OEM mode (pending final verification). I am going to move this to review and proceed with slideshow touch-up separately as it's only related on a technical but not functional level.

To use oem mode

  • BIOS systems: hit esc during first splash ➔ boot menu comes up ➔ hit f4 ➔ change mode to OEM ➔ hit enter to boot
  • UEFI systems: in ISO GRUB hit e to edit the entry ➔ append oem-config/enable=true to the initrd line ➔ hit ctrl-x to boot

Session will look much the same but the installer itself will say something like 'Install Neon - OEM mode' in the window frame and the user setup will have oem as user name pre-set-up. Once installed the system will boot into OEM preparation mode. In this mode the system can be altered as necessary (updates applied, software installed, install languages etc.).
Once the system is ready to ship it can be switched into firstboot mode by running sudo oem-config-prepare. On the next boot the first start wizard comes up to guide the user through setting up keyboard/locale/timezone/user. Once complete the system is ready to use.

works good on uefi and bios, well done. It may be polite to e-mail any fixes to ubiquity to kubuntu as they've had it broken for years.

implementing this in calamares is another job coming soon.

jriddell closed this task as Resolved.Jan 24 2017, 2:10 PM