Skip to content

ci: Add snapcraft publish action#418

Open
ottnorml wants to merge 1 commit intozidoro:masterfrom
ottnorml:ci/snapcraft-releaser
Open

ci: Add snapcraft publish action#418
ottnorml wants to merge 1 commit intozidoro:masterfrom
ottnorml:ci/snapcraft-releaser

Conversation

@ottnorml
Copy link
Contributor

@ottnorml ottnorml commented Oct 4, 2023

For this action to work the secrets SNAPCRAFT_STORE_LOGIN must be available.

For the snapcraft publish action to work, the SNAPCRAFT_STORE_LOGIN secret must be available. It can be created as described in the documentation of the action (see link). It should be noted that the name of the secret is different from the one in the documentation to be more readable.

$ snapcraft export-login --snaps=PACKAGE_NAME \
      --acls package_access,package_push,package_update,package_release \
      exported.txt

refs #412, #418

SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_LOGIN }}
with:
snap: "*.snap"
release: stable
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how the Snapcraft publishing works for Pomatez, since all channels (latest/stable, latest/candidate, latest/beta, latest/edge) offer the same latest version (see link).

So I decided to use only the stable channel. But this can be easily changed or extendedBut this can be easily changed or extended, like this for example:

release: ${{ startsWith(github.ref, 'refs/tags/') && 'candidate' || 'edge'}}

Taken from https://ubuntu.com/robotics/docs/build-and-publish-a-ros-snap-with-github-actions.

Copy link
Member

@roldanjr roldanjr Oct 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have used the Snapcraft official way of building the Snap package before as you can see here. It triggers when there is a new version released and automatically uploads to the SnapStore but in the edge channel which is ideal then I promote the latest version on the edge to the other channels once I tested it on a Linux machine that it still worked as expected.

But the Snapcraft GitHub integration has been broken and I don't know what happened to why new builds are failing, maybe it is due to some breaking changes on their end that I failed to be updated also, so I decided to remove the integration though I didn't delete the folder yet cause I was thinking it might still be useful for future reference. Right now, I just manually download the snap package here and upload it manually on SnapStore.

@sekwah41
Copy link
Collaborator

sekwah41 commented Dec 8, 2025

Need to take a look a this, might need to get @roldanjr to add access for me to take a look at the snapcraft side.

@sekwah41
Copy link
Collaborator

I've now been added as a maintainer to that so should be able to look when I get time :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants