This post is related to my earlier post:
I went ahead and downloaded the pi project from github, edited the snapcraft.yaml (including a rename of the snap from pi to epi-pi to reflect my local changes).
I installed ubuntu-image
I created the model assertion file and signed it with my key. All OK except I cannot find definitive guide of how to make a model assertion file which lets you use a local snap. I was reading this post: Anyway this is my model assertion file:
{ “type”: “model”, “authority-id”: “HNWdnNMKNv0zCKCsnvz7ijg8GXapu498”, “brand-id”: “HNWdnNMKNv0zCKCsnvz7ijg8GXapu498”, “series”: “16”, “model”: “epi-gateway-os-core-20-rpi4-arm64”, “display-name”:“EpiSensor Gateway OS (Core20, RPi4, arm64)”, “architecture”: “arm64”, “base”: “core20”, “grade”: “dangerous”, “timestamp”: “2022-10-07T11:00:10+00:00”, “snaps”: [ { “name”: “core”, “type”: “core”, “default-channel”: “latest/stable”, “id”: “99T7MUlRhtI3U0QFgl5mXXESAiSwt776” }, { “name”: “core18”, “type”: “base”, “default-channel”: “latest/stable”, “id”: “CSO04Jhav2yK0uz97cr0ipQRyqg0qQL6” }, { “name”: “core20”, “type”: “base”, “default-channel”: “latest/stable”, “id”: “DLqre5XGLbDqg9jPtiAhRRjDuPVa5X1q” }, { ** “name”: “epi-pi”,** ** “type”: “gadget”** ** },** { “name”: “pi-kernel”, “type”: “kernel”, “default-channel”: “20/stable”, “id”: “jeIuP6tfFrvAdic8DMWqHmoaoukAPNbJ” }, { “name”: “snapd”, “type”: “snapd”, “default-channel”: “latest/stable”, “id”: “PMrrV4ml8uWuEUDBT8dSGnKUYbevVhc4” }, { “name”: “network-manager”, “type”: “app”, “default-channel”: “20/stable”, “id”: “RmBXKl6HO6YOC2DE4G2q1JzWImC04EUy” }, { “name”: “modem-manager”, “type”: “app”, “default-channel”: “20/stable”, “id”: “KtwxgRlwCAVKFw92BUdt1WloH1Va3QPo” } ] }
When I run ubuntu-image I get the following: sudo ubuntu-image snap -c stable --snap epi-pi -O image epi-gateway-os-core20-arm64.model \WARNING: proceeding to download snaps ignoring validations, this default will change in the future. For now use --validation=enforce for validations to be taken into account, pass instead --validation=ignore to preserve current behavior going forward Error: Error preparing image: cannot download snap “epi-pi”: snap not found
I have tried many other variant e.g. omitting gadget snap from model assertion, using gadget: line in model assertion and now I am going around in circles.
This is the system I want to create: episensor@zgw-10-611bb0:~$ snap list
Name Version Rev Tracking Publisher Notes
core 16-2.57.1 13746 latest/stable canonical✓ core
core18 20220831 2570 latest/stable canonical✓ base
core20 20220826 1627 latest/stable canonical✓ base - -
modem-manager 1.16.6-2 471 20/stable canonical✓ -
network-manager 1.22.10-14 743 20/stable canonical✓ -
epi-pi TBD TBD - - gadget
pi-kernel 5.4.0-1070.80 525 20/stable canonical✓ kernel
snapd 2.57.1 16782 latest/stable canonical✓ snapd
Can someone provide some tips, I would really appreciate it as I am stuck on this for days?
Also the example in this post in out of date as the --extra-snaps argument is no longer accepted it seems