Closed gruyaume closed 3 months ago
I already have a Snapcraft account: ldez But I don't have Snapcraft forum login.
I already have a Snapcraft account: ldez But I don't have Snapcraft forum login.
Ok, I just made the request:
Before the transfer can you add the v4.16.0 to the current snap?
Before the transfer can you add the v4.16.0 to the current snap?
Done!
@ldez As you can see in the snapcraft request, I first need to add you as a collaborator on the snap and I need your email for this.
My email is: -
I accepted the invitation
@ldez The transfer is complete. Let me know when the snapcraft token is in the repo secrets and I'll move the PR to live.
I can't find the Snapcraft token inside my Snapcraft account, where is it?
I can't find the Snapcraft token inside my Snapcraft account, where is it?
You will have to generate one for yourself via snapcraft CLI:
It's unexpected to be forced to install a CLI to generate a token, but :shrug:
I added the token to the secrets.
It's unexpected to be forced to install a CLI to generate a token, but 🤷
Well the token is used by the CLI, you are "forced" to install the cli to use the token as well...
Everything is ok? Ready for review?
Everything is ok? Ready for review?
I think so, but it's hard to test the PR without running the release.
We will see with the next release :smile:
The release fails:
Run snapcraft login
snapcraft login
shell: /usr/bin/bash -e {0}
env:
GO_VERSION: stable
CGO_ENABLED: 0
SNAPCRAFT_STORE_CREDENTIALS: ***
Cannot login with 'SNAPCRAFT_STORE_CREDENTIALS' set.
Recommended resolution: Unset 'SNAPCRAFT_STORE_CREDENTIALS' and try again.
Full execution log: '/home/runner/.local/state/snapcraft/log/snapcraft-20240528-105206.532861.log'
Error: Process completed with exit code 1.
https://github.com/go-acme/lego/actions/runs/9267967862/job/25495567069
I fixed the first problem but there is another one:
⨯ release failed after 44m55s error=failed to generate snap package: exit status 1: Packing...
Creating snap package...
Command '['snap', 'pack', '--filename', 'lego_4.17.2_linux_armv7.snap', 'dist/lego_4.17.2_linux_armv7/prime', PosixPath('/home/runner/work/lego/lego/dist')]' returned non-zero exit status 1.
Full execution log: '/home/runner/.local/state/snapcraft/log/snapcraft-20240528-135337.553506.log'
Error: The process '/opt/hostedtoolcache/goreleaser-action/1.26.2/x64/goreleaser' failed with exit code 1
https://github.com/go-acme/lego/actions/runs/9269740662/job/25501184725
I'm not able to debug that, there is not enough information. Each try takes about 1 hour, I already created 2 bug-fix releases so I will disable the snap step.
Description
The LEGO snap makes it easy to install and use LEGO on any Linux distribution that supports snaps. This PR adds the snap to go releaser to automatically build and publish the snap.
Usage
Note: The LEGO snap can only write to the
/var/snap/lego/common/.lego
directory.Confinement
The snap is strictly confined, meaning it only has access to what it requires to work and for LEGO that means network binding.
Snap publishing
For the snap publishing to succeed, it will be necessary to do the following before merging this PR:
lego
snap name switched from myself to this new account. I can make the request myself once we have step 1 completed.SNAPCRAFT_STORE_CREDENTIALS
Once all of those are completed, I will move the PR from draft to live.
Channel
With the current state of the change proposed here, the snap will be automatically published to the
edge
channel. This means that promotion from edge -> beta -> candidate -> stable would have to be done manually through the Snapcraft UI.Related to https://github.com/go-acme/lego/discussions/2133