Add .deb package generation for Linux releases#18
Merged
Conversation
Adds debArch to Linux matrix entries and a dpkg-deb build step that creates .deb packages for each Linux architecture on release. Packages install the binary to /usr/local/bin/. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Install to /usr/bin instead of /usr/local/bin (Debian FHS policy) - Add --clobber to gh release upload for idempotent re-runs - Use env.APP_NAME where defined for consistency - Add missing debArch to matrix entries (http_trace) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Owner
Author
🧪 .deb Package Test ResultsTest environment: podman + debian:bookworm-slim (amd64)
Package structure is valid. Binary execution requires glibc 2.38+ (built on |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
.debpackage generation to the release workflow for all Linux architectures. As a template repo, this demonstrates how to produce Debian packages from a Rust CI pipeline.Changes
debArchfield to each Linux target in the build matrix (i386,amd64,armel,armhf,arm64)Build .deb packagestep that usesdpkg-debto create Debian packages after the binary is compiledUpload .deb Release Assetstep with--clobberfor idempotent re-runsenv.APP_NAMEconsistently for binary paths and package naming/usr/bin/hello_worldHow it works
On a
releaseevent, each Linux matrix job creates a.debpackage usingdpkg-deb --build. The package contains the binary at/usr/bin/hello_worldand aDEBIAN/controlfile with package name, version (from the release tag), and architecture. The.debis uploaded to the GitHub Release alongside existing raw binaries.Architectures
amd64x86_64-unknown-linux-gnui386i686-unknown-linux-gnuarm64aarch64-unknown-linux-gnuarmhfarmv7-unknown-linux-gnueabihfarmelarm-unknown-linux-gnueabiUsage