--- apiVersion: v1 kind: PersistentVolumeClaim metadata: name: pkg-repo-pvc namespace: pkg-repo spec: storageClassName: longhorn accessModes: [ReadWriteOnce] resources: requests: storage: 10Gi --- apiVersion: v1 kind: ConfigMap metadata: name: reprepro-config namespace: pkg-repo data: distributions: | Codename: trixie Suite: stable Components: main Architectures: amd64 arm64 SignWith: yes options: | basedir /repo/debian init.sh: | #!/bin/bash set -e # Install reprepro (one-time, cached in PVC) if ! command -v reprepro &>/dev/null; then apt-get update && apt-get install -y --no-install-recommends reprepro gpg gpg-agent rm -rf /var/lib/apt/lists/* fi # Import GPG key gpg --batch --import /gpg/private.key 2>/dev/null || true # Export public key for clients gpg --armor --export > /repo/pubkey.gpg # Always ensure conf is up-to-date and repo is initialized mkdir -p /repo/debian/conf cp /config/distributions /repo/debian/conf/ cp /config/options /repo/debian/conf/ # Export (initialize or re-sign) the repo cd /repo/debian && reprepro export # Index page cat > /repo/index.html <<'HTML'