ogra
April 23, 2020, 10:39am
10
closing channels only helps for already built snaps indeed … to prevent your snap from building on unwanted arches you need to use the architectures:
option in snapcraft.yaml:
By default, Snapcraft builds a snap to run on the same architecture as the build environment. This behaviour can be modified with the top-level keywords architectures and platforms in the snap’s snapcraft.yaml.
The architectures and platforms keywords are used to create a build plan. See build plans for an explanation of how build plans are created.
The keywords are base-dependent:
platforms is used for core24 snaps
architectures is used for core20 and core22 snaps
How to create a snap for …
i.e.:
architectures:
- build-on: [ amd64, armhf ]
to build only on these two arches …
1 Like