@pedronis, I have updated to the latest ubuntu-image with this fix. I created the connections stanza according to the specified syntax from @niemeyer. I can successfully create an Ubuntu Core image, however, snpad (2.34.3) in the built Ubuntu Core image is not auto connecting these plugs to the specified slot.
Has any one had a chance to verify this solution on Ubuntu Image?
Below is my gadget.yaml file
volumes:
pc:
bootloader: grub
structure:
- name: mbr
type: mbr
size: 440
content:
- image: pc-boot.img
- name: BIOS Boot
type: DA,21686148-6449-6E6F-744E-656564454649
size: 1M
offset: 1M
offset-write: mbr+92
content:
- image: pc-core.img
- name: EFI System
type: EF,C12A7328-F81F-11D2-BA4B-00A0C93EC93B
filesystem: vfat
filesystem-label: system-boot
size: 50M
content:
- source: grubx64.efi
target: EFI/boot/grubx64.efi
- source: shim.efi.signed
target: EFI/boot/bootx64.efi
- source: grub.cfg
target: EFI/ubuntu/grub.cfg
#Auto connect below
connections:
- plug: mycustomsnap:hardware-observe
slot: core:hardware-observe
- plug: mycustomsnap:shutdown
slot: core:shutdown
- plug: mycustomsnap:snapd-control
slot: core:snapd-control
- plug: mycustomsnap:tpm
slot: core:tpm
- plug: mycustomsnap:gpio
slot: mygadgetsnap:gpio-5
- plug: mycustomsnap:gpio
slot: mygadgetsnap:gpio-6
- plug: mycustomsnap:gpio
slot: mygadgetsnap:gpio-7
- plug: mycustomsnap:gpio
slot: mygadgetsnap:gpio-438