snapd icon indicating copy to clipboard operation
snapd copied to clipboard

o/devicestate, o/snapstate: improve firstboot task order

Open ernestl opened this issue 1 year ago • 2 comments

Make corrections to firstboot install task order according to spec SD154 | Firstboot install task order

This task draws inspiration from earlier, dated work to achieve the same: https://github.com/canonical/snapd/pull/13127

enable firstboot to request configuration using gadget defaults instead of injecting the task itself

  • Adapting install code to generate configuration task, using gadget defaults, for essential snaps: core, gadget and kernel to avoid injecting configure tasks from the first boot install code. The exception remains when core snap is not installed, a configuration need to be injected.
  • Introduced configure edge, that is required to provide reference for reorganizing the install taskset within the firstboot code.
  • None of the tests are affected at this point, but little more simplification is required once the firstboot code changes and stop injecting configure hooks for essential snaps.

JIRA: https://warthogs.atlassian.net/browse/SNAPDENG-7297

ernestl avatar Feb 03 '25 11:02 ernestl

Thu Mar 20 14:44:41 UTC 2025

Spread tests skipped

github-actions[bot] avatar Feb 03 '25 11:02 github-actions[bot]

Codecov Report

Attention: Patch coverage is 67.56757% with 108 lines in your changes missing coverage. Please review.

Please upload report for BASE (master@81fd929). Learn more about missing BASE report. Report is 181 commits behind head on master.

Files with missing lines Patch % Lines
...lord/devicestate/devicestatetest/task_run_order.go 0.00% 85 Missing :warning:
overlord/devicestate/firstboot.go 91.48% 12 Missing and 4 partials :warning:
overlord/snapstate/snapstate.go 88.09% 4 Missing and 1 partial :warning:
overlord/snapstate/target.go 33.33% 1 Missing and 1 partial :warning:
Additional details and impacted files
@@            Coverage Diff            @@
##             master   #15015   +/-   ##
=========================================
  Coverage          ?   78.09%           
=========================================
  Files             ?     1171           
  Lines             ?   157042           
  Branches          ?        0           
=========================================
  Hits              ?   122637           
  Misses            ?    26795           
  Partials          ?     7610           
Flag Coverage Δ
unittests 78.09% <67.56%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Feb 09 '25 08:02 codecov[bot]