Use triggering conditions for controlling when console-conf should run. We
effectively want it to start if there is no /var/lib/console-conf/complete
file *or* the snapd recovery marker file exists.
Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com>
These are currently applied with hacks in the core18 repo when building the
core18 snap, but that was always meant to be a temporary thing until it was
upstreamed... here's the upstreaming.
Signed-off-by: Ian Johnson <ian.johnson@canonical.com>
On Core20 devices, the user may decice to invoke a recovery chooser by holding
down a specific key. Make sure that the recovery chooser trigger detection
service runs before, so that by the time console-conf runs, the trigger
detection window is closed and we may launch the chooser if needed.
Note, the patch only includes the bits for ensuring the correct order during
boot.
Signed-off-by: Maciek Borzecki <maciek.borzecki@gmail.com>
The service is named core.start-snapd.service in core20. Add a comment
explaining why we need this.
Signed-off-by: Maciek Borzecki <maciek.borzecki@gmail.com>
On core18 the firstboot seeding happens via the core18.start-snapd
service. This service will do the initial start of snapd when the
system is unseeded. This service will wait until the system is
fully seeded.
We cannot run console-conf before that because it uses the "snap"
command which will not be available before the system is seeded.
Once that has landed https://github.com/snapcore/core18/pull/74
can be reverted (in fact the hooks/200-console-conf-after.chroot
file can be removed entirely).
The main visible effect of this is that if console-conf crashes or is killed
it restarts instantly rather than 90 seconds later. It also removes the flicker
where a getty gets started and then instantly killed during startup.
* debian/console-conf.*.serial: Start the console-conf wrappers from
their path in /usr/share/subiquity; no need to have them in /usr/bin.
* bin/console-conf-serial-wrapper: add --serial to the command-line.
* debian/console-conf.serial-console-conf@.service: don't pass --serial,
this is meant to be parameters to agetty, not to the login program.