From f186b71ca51e83837db60de13322394bb5e6d348 Mon Sep 17 00:00:00 2001 From: murilo ijanc Date: Tue, 24 Mar 2026 21:41:06 -0300 Subject: Initial commit Import existing tesseras.net website content. --- news/packaging-debian/index.html | 157 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 157 insertions(+) create mode 100644 news/packaging-debian/index.html (limited to 'news/packaging-debian/index.html') diff --git a/news/packaging-debian/index.html b/news/packaging-debian/index.html new file mode 100644 index 0000000..bfe7563 --- /dev/null +++ b/news/packaging-debian/index.html @@ -0,0 +1,157 @@ + + + + + + Packaging Tesseras for Debian — Tesseras + + + + + + + + + + + + + + + + + + + + + + + + +
+

+ + + Tesseras + +

+ + +
+ +
+ +
+

Packaging Tesseras for Debian

+

2026-02-16

+

Tesseras now ships a .deb package for Debian and Ubuntu. This post walks +through building and installing the package from source using cargo-deb.

+

Prerequisites

+

You need a working Rust toolchain and the required system libraries:

+
sudo apt install build-essential pkg-config libsqlite3-dev
+rustup toolchain install stable
+cargo install cargo-deb
+
+

Building

+

Clone the repository and run the just deb recipe:

+
git clone https://git.sr.ht/~ijanc/tesseras
+cd tesseras
+just deb
+
+

This recipe does three things:

+
    +
  1. Compiles tesd (the daemon) and tes (the CLI) in release mode with +cargo build --release
  2. +
  3. Generates shell completions for bash, zsh, and fish from the tes binary
  4. +
  5. Packages everything into a .deb file with +cargo deb -p tesseras-daemon --no-build
  6. +
+

The result is a .deb file in target/debian/.

+

Installing

+
sudo dpkg -i target/debian/tesseras-daemon_*.deb
+
+

If there are missing dependencies, fix them with:

+
sudo apt install -f
+
+

Post-install setup

+

The postinst script automatically creates a tesseras system user and the +data directory /var/lib/tesseras. To use the CLI without sudo, add yourself to +the group:

+
sudo usermod -aG tesseras $USER
+
+

Log out and back in, then start the daemon:

+
sudo systemctl enable --now tesd
+
+

What the package includes

+ + + + + + +
PathDescription
/usr/bin/tesdFull node daemon
/usr/bin/tesCLI client
/etc/tesseras/config.tomlDefault configuration (marked as conffile)
/lib/systemd/system/tesd.serviceSystemd unit with security hardening
Shell completionsbash, zsh, and fish
+

How cargo-deb works

+

The packaging metadata lives in crates/tesseras-daemon/Cargo.toml under +[package.metadata.deb]. This section defines:

+ +

The postinst script creates the tesseras system user and data directory on +install. The postrm script cleans up the user, group, and data directory only +on purge (not on simple removal).

+

Systemd hardening

+

The tesd.service unit includes security hardening directives:

+
NoNewPrivileges=true
+ProtectSystem=strict
+ProtectHome=true
+ReadWritePaths=/var/lib/tesseras
+PrivateTmp=true
+PrivateDevices=true
+ProtectKernelTunables=true
+ProtectControlGroups=true
+RestrictSUIDSGID=true
+MemoryDenyWriteExecute=true
+
+

The daemon runs as the unprivileged tesseras user and can only write to +/var/lib/tesseras.

+

Deploying to a remote server

+

The justfile includes a deploy recipe for pushing the .deb to a remote host:

+
just deploy bootstrap1.tesseras.net
+
+

This builds the .deb, copies it via scp, installs it with dpkg -i, and +restarts the tesd service.

+

Updating

+

After pulling new changes, simply run just deb again and reinstall:

+
git pull
+just deb
+sudo dpkg -i target/debian/tesseras-daemon_*.deb
+
+ +
+ +
+ + + + -- cgit v1.2.3