stage-snaps not usable with a brand store

Bug #1833220 reported by Ian Johnson on 2019-06-18
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
Undecided
Unassigned

Bug Description

It's not possible AFAICT to configure snapcraft to download snaps from a brand store with build-snaps or stage-snaps. Poking around at the source, it looks like snapcraft is downloading snaps with this function: https://github.com/snapcore/snapcraft/blob/master/snapcraft/internal/repo/snaps.py#L163-L175

which if I run `snap download` outside of snapcraft I am able to download snaps from my brand store by specifying the env vars:

UBUNTU_STORE_AUTH_DATA_FILENAME=./creds UBUNTU_STORE_ID=my-cool-brand-store-id snap download my-cool-brand-store-snap --edge

(where creds is from snapcraft export-login)

Attempting to provide this env vars to snapcraft doesn't seem to propogate them to the snap download command that snapcraft runs. I.e. this fails:

UBUNTU_STORE_AUTH_DATA_FILENAME=./creds UBUNTU_STORE_ID=my-cool-brand-store-id snapcraft

It also fails in destructive-mode:

UBUNTU_STORE_AUTH_DATA_FILENAME=./creds UBUNTU_STORE_ID=my-cool-brand-store-id snapcraft --destructive-mode

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers