Split the packages, publish releases from Gitea Actions, release 0.1.0
release / release (push) Successful in 7m7s

make deb now builds two packages: jarl-cli (the CLI, its completion and
the ACME hooks, no scripts) and jarl (the server), which depends on
jarl-cli of the same version.

Pushing a v* tag runs .gitea/workflows/release.yml: it tests, builds the
tarballs, the CLI for Linux, macOS and Windows (make cli-dist) and the
.debs for amd64 and arm64, then scripts/gitea-release.sh creates the
Gitea release and uploads the .debs to the Debian package registry, so
servers install and upgrade with apt. The stats package's inode lookup
is split by OS so the CLI builds for Windows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
abrown38andClaude Opus 5.5 committed 2026-10-09 08:40:56 +00:00
1 parent 293e6ddd33
commit 4d00be53c3
16 files changed
+450 -84

No files matched your search

+16 -3
View File
@@ -6,9 +6,12 @@
# make e2e end-to-end test against a real named (scripts/e2e.sh)
# sudo make install install binaries, bash completion, systemd units,
# sysusers/tmpfiles files and an example /etc/jarl/jarl.yaml
# make deb a Debian package in dist/ (DEB_ARCH=arm64 for another
# architecture); install it with 'sudo apt install ./dist/jarl_*.deb'
# make deb Debian packages in dist/ (DEB_ARCH=arm64 for another
# architecture): jarl (the server) and jarl-cli (the CLI,
# which jarl depends on); 'sudo apt install ./dist/jarl*_amd64.deb'
# make dist static binaries for linux/amd64 and linux/arm64 in dist/
# make cli-dist the CLI alone for Linux, macOS and Windows in dist/
# (jarl-cli-<version>-<os>-<arch>[.exe])
VERSION ?= $(shell cat VERSION 2>/dev/null || echo 0.0.0-dev)
LDFLAGS := -s -w -X jarl/internal/version.Version=$(VERSION)
@@ -34,7 +37,7 @@ JARL_BIN ?= bin/jarl
DEB_ARCH ?= $(shell dpkg --print-architecture 2>/dev/null || go env GOARCH)
DEB_VERSION ?= $(subst -,~,$(VERSION))
.PHONY: all build completion test vet e2e install install-files uninstall deb dist clean
.PHONY: all build completion test vet e2e install install-files uninstall deb dist cli-dist clean
all: build
@@ -114,5 +117,15 @@ dist: build
tar -C dist -czf dist/jarl-$(VERSION)-linux-$$arch.tar.gz jarl-$(VERSION)-linux-$$arch || exit 1; \
done
# The platforms cli-dist builds the CLI for.
CLI_PLATFORMS ?= linux/amd64 linux/arm64 darwin/amd64 darwin/arm64 windows/amd64 windows/arm64
cli-dist:
@mkdir -p dist
for p in $(CLI_PLATFORMS); do \
os=$${p%/*} arch=$${p#*/} ext=; [ $$os = windows ] && ext=.exe; \
GOOS=$$os GOARCH=$$arch go build $(GOFLAGS) -ldflags '$(LDFLAGS)' -o dist/jarl-cli-$(VERSION)-$$os-$$arch$$ext ./cmd/jarl || exit 1; \
done
clean:
rm -rf bin dist