AddingImages
Adding new Ubuntu Core images/devices to the build process is very similar to that of Ubuntu Appliances.
- Make sure the new image/device has all the required snaps present in the snapstore. Some questions to answer:
- Is it a completely new device with completely new gadget+kernel combination?
- Is the kernel snap available for the device? Is it on the right track? (20/* for UC20, 18/* for UC18 etc)
- Is the gadget snap available for the device? Same for the tracks.
- What arches should it be provided for? Some devices support multiple architectures (armhf, arm64 etc.)
- Does it need any other device-specific snaps preinstalled?
What should be the name of the new model? We usually follow the naming of: ubuntu-core-<SERIES>-<PLATFORM>[-<ARCH>][-<GRADE or STABILITY>], e.g. ubuntu-core-20-pi-arm64-dangerous.
Create the new image model assertion JSON files, one per each supported arch. Please consult existing model JSON files for reference on how the fields should look like. There is a snapcore/models git repository with all the officially supported models so far.
- When creating a model JSON file remember to bump the timestamp at the bottom to the current date
- The publisher and brand should be 'canonical'
Do a test build of the new model to make sure no error sneaked in. This can be done by substituting the brand-id and authority-id's from canonical to your private ones and signing the assertions locally, then using ubuntu-image snap as usual.
- Create an RT for IS to sign the model assertion with the canonical key, attaching the relevant .json files to the RT.
- Example request - RT: 131731.
Commit the new assertion and related JSON file to the snapcore/models github repository.
Once the model assertion is signed, send the signed model files to snap-store-admins@lists.canonical.com for upload to the Snap Store.
Add support for the new model in livecd-rootfs for the selected series (UC20 = focal, UC18 = bionic etc.).
livecd-rootfs translates the <ARCH>+<SUBARCH> cdimage pair into the model name.
- This requires deciding on what SUBARCH should be used for the new image. When planning, keep in mind the possibility of us enabling the same platform for classic images.
The actual support for the translation to model name is in live-build/auto/config in livecd-rootfs. Look for a conditional switch for ubuntu-image IMAGEFORMAT.
Prepare SRU for the livecd-rootfs changes, make sure it's verified and released into <SERIES>-updates
To officially build the new image alongside all the other default Ubuntu Core images, add the new <ARCH>+<SUBARCH> pair to etc/default-arches in lp:ubuntu-cdimage (under the ubuntu-core project)
Once there is a physical image built on cdimage, give the link to the new builds to the CertificationTeam (contact: Paul or Jonathan)
UbuntuCore/AddingImages (last edited 2021-07-09 09:10:39 by sil2100)