Skip to content

Commit

Permalink
chore: add snap to release packages (#2134)
Browse files Browse the repository at this point in the history
  • Loading branch information
gruyaume authored Mar 15, 2024
1 parent 441775e commit 61553c4
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ jobs:
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
run: echo "${DOCKER_PASSWORD}" | docker login --username "${DOCKER_USERNAME}" --password-stdin

- name: Install snapcraft
run: sudo snap install snapcraft --classic

- name: Snapcraft login
env:
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }}
run: snapcraft login

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

Expand Down
28 changes: 28 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,3 +141,31 @@ dockers:
- '--label=org.opencontainers.image.revision={{.FullCommit}}'
- '--label=org.opencontainers.image.version={{.Version}}'
- '--platform=linux/arm/v7'

snapcrafts:
- name: lego
grade: stable
confinement: strict
license: MIT
base: core22
publish: true
summary: Lego is a Let's Encrypt/ACME client.
description: |
Lego is a Let's Encrypt/ACME client written in Go.
The lego snap makes it easy to install and use Lego on any Linux distribution that supports snaps.
Usage:
* `sudo snap install lego`
* `sudo lego --email="you@example.com" --domains="example.com" --server=https://acme-staging-v02.api.letsencrypt.org/directory --http --http.port :8080 run
channel_templates:
- edge

apps:
lego:
command: bin/lego
environment:
LEGO_PATH: /var/snap/lego/common/.lego
plugs:
- network-bind
6 changes: 6 additions & 0 deletions docs/content/installation/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ docker run goacme/lego -h
yay -S lego-bin
```

- [Snap](https://snapcraft.io/lego) (official):

```bash
sudo snap install lego
```

- [FreeBSD (Ports)](https://www.freshports.org/security/lego) (unofficial):

```bash
Expand Down

0 comments on commit 61553c4

Please sign in to comment.