#!/usr/bin/env bash set -Eeuo pipefail source /opt/rust-package-builder/scripts/lib.sh OUT=${1:?output file required} PACKAGE=${2:?package name required} URL=$(trim_trailing_slash "$REPOSITORY_URL") export OUT PACKAGE URL OPNSENSE_REPOSITORY_URL REPO_DISTRIBUTION REPO_COMPONENT python3 <<'PY_END' import html, os out=os.environ['OUT'] package=os.environ['PACKAGE'] url=os.environ['URL'] dist=os.environ['REPO_DISTRIBUTION'] component=os.environ['REPO_COMPONENT'] opn_url=os.environ['OPNSENSE_REPOSITORY_URL'].rstrip('/') h=html.escape content=f'''
Signed DEB and RPM packages for x86_64/amd64.
curl -fsSL {h(url)}/repo-key.gpg \\
| sudo gpg --dearmor -o /usr/share/keyrings/{h(package)}.gpg
echo "deb [signed-by=/usr/share/keyrings/{h(package)}.gpg] {h(url)}/apt {h(dist)} {h(component)}" \\
| sudo tee /etc/apt/sources.list.d/{h(package)}.list
sudo apt update
sudo apt install {h(package)}
sudo rpm --import {h(url)}/repo-key.gpg
sudo tee /etc/yum.repos.d/{h(package)}.repo <<'REPO'
[{h(package)}]
name={h(package)} Repository
baseurl={h(url)}/rpm/$basearch
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey={h(url)}/repo-key.gpg
REPO
sudo dnf install {h(package)}
Install rustproxy-docker-agent on the Docker host (systemd, Docker Engine, amd64/x86_64). This is independent from the RustProxy server and has no FreeBSD pkg.
# Debian / Ubuntu (after adding the signed APT repo above)
sudo apt install rustproxy-docker-agent
# RHEL / Rocky / Alma / Fedora (after adding the DNF repo above)
sudo dnf install rustproxy-docker-agent
# Locally display the token and certificate fingerprint
sudo rustproxy-docker-agent info --show-token
sudo systemctl status rustproxy-docker-agent
Packages create persistent credentials and a systemd service; tokens are never printed to unattended package logs. Restrict the agent's HTTPS port to the RustProxy host.
The OPNsense plugin is published separately because it uses the FreeBSD pkg format.
Native FreeBSD pkg (if enabled): {h(opn_url)}/freebsd/.
Supported targets: Debian 12/13, Ubuntu 24.04/26.04, RHEL 9/10; architecture: amd64/x86_64.