Snapcraft Travis CI Com/Org Address Error

I went through the tutorial to set up Travis CI with Snapcraft. After a good amount of trial and error I found out that the snapcraft enable-ci travis command does not set up the environmental variables for the builds correctly since May 2018 when TravisCI is moving all builds to travisci.com from travisci.org.

The builds are triggered on the .com variant where snapcraft did not place the environmental variables, whereas they exist on the .org variant. Travis doesn’t let you access the encrypted variables so I can’t transfer them over.

Any thoughts on how I can get those variables and move them over or fix this issue?

1 Like

Thanks for bringing this to our attention, please can you file a bug here:

Please paste a link to the bug in this topic so @sergiusens and @kyrofa see it :slight_smile:

1 Like

We don’t really recommend the enable-ci command these days. I suggest running snapcraft export-login --snaps <snap name> --channels edge --acls package_upload -, copying the token that it prints, and just putting it in a variable on your own. Then you can use it with echo "$TOKEN_VARIABLE" | snapcraft login --with -.

1 Like

bug is filed here https://bugs.launchpad.net/snapcraft/+bug/1784053

thanks! The snapcraft / Travis tutorial should probably be updated then