temp: real audit

This commit is contained in:
hermes-agent committed 2026-11-02 18:08:18 +01:00
1 parent a1505932e4
commit ad263f1bcc
1 file changed
+13 -8
+13 -8
View File
@@ -5,13 +5,18 @@ jobs:
audit:
runs-on: nixos
steps:
- name: locate container runtime
- name: gitea storage audit as root (read-only mount)
run: |
set +e
echo "== PATH=$PATH"
for c in docker podman; do
p=$(command -v $c); echo "$c -> $p"
done
ls -l /run/current-system/sw/bin/ 2>/dev/null | grep -Ei 'docker|podman' | head
echo "== docker sock"; ls -l /var/run/docker.sock /run/podman/podman.sock 2>&1
echo "== images"; /run/current-system/sw/bin/docker images 2>&1 | head -20
/run/current-system/sw/bin/docker run --rm -v /mnt/appdata:/a:ro ubuntu:24.04 bash -c '
echo "== gitea top-level"; du -xsh /a/gitea/* 2>&1 | sort -h
echo "== gitea/data"; du -xsh /a/gitea/data/* 2>&1 | sort -h
echo "== dumps"; ls -1 /a/gitea/dumps 2>/dev/null | wc -l; du -xsh /a/gitea/dumps 2>/dev/null
echo "== repos: owner/repo (top 40)"
du -xsh /a/gitea/data/gitea-repositories/*/* 2>/dev/null | sort -h | tail -40
echo "== lfs"; du -xsh /a/gitea/data/lfs 2>/dev/null
echo "== packages"; du -xsh /a/gitea/data/packages 2>/dev/null
echo "== repo count"; ls -1d /a/gitea/data/gitea-repositories/*/* 2>/dev/null | wc -l
echo "== biggest files >100M"
find /a/gitea -xdev -type f -size +100M -printf "%s %p\n" 2>/dev/null | sort -n | tail -25
'