Files
mtusi2026lab7/scripts/test_all.sh
T

39 lines
2.4 KiB
Bash
Executable File

#!/bin/sh
set -eu
cd "$(dirname "$0")/.."
export CA_FILE="$PWD/.secrets/ca.crt"
mkdir -p evidence
./scripts/operator.sh python scripts/provision.py clear-rate >/dev/null
make check >evidence/check.txt
make validate PYTHON=.venv/bin/python >evidence/validate.txt
make audit >evidence/audit-summary.txt
make test CA_FILE="$CA_FILE" >evidence/smoke.txt
make test-security CA_FILE="$CA_FILE" >evidence/public-security.txt
./scripts/operator.sh python tests/security_controls.py >evidence/security-controls.json
./scripts/operator.sh python tests/uploads_negative.py >evidence/uploads-negative.json
./scripts/operator.sh python tests/image_variants.py >evidence/image-variants.json
./scripts/operator.sh python scripts/provision.py clear-rate >/dev/null
.venv/bin/python tests/idempotency_concurrent.py >evidence/idempotency.json
.venv/bin/python tests/bao_policy.py >evidence/bao-policy.json
./scripts/operator.sh python tests/database_auth.py >evidence/database-auth.json
.venv/bin/python scripts/prepare_probes.py >/dev/null
./scripts/compose.sh run --rm --no-deps -v "$PWD/.secrets/roles:/run/probes:ro" operator python service.py operator python tests/tls_matrix.py >evidence/tls-matrix.json
./scripts/operator.sh python scripts/provision.py clear-rate >/dev/null
make test-persistence ACTION_SCRIPT=scripts/restart.sh CA_FILE="$CA_FILE" >evidence/persistence.txt
.venv/bin/python scripts/wait_ready.py >/dev/null
.venv/bin/python tests/failover_each.py >evidence/failover-each.json
./scripts/operator.sh python scripts/provision.py clear-rate >/dev/null
.venv/bin/python tests/observability.py >evidence/observability.json
.venv/bin/python tests/lifecycle.py >evidence/lifecycle.json
.venv/bin/python tests/compromise_research.py >evidence/research.txt
.venv/bin/python scripts/research_graphs.py
.venv/bin/python scripts/bootstrap_pki_test.py >evidence/fresh-pki-bootstrap.json
.venv/bin/python scripts/bootstrap_postgres_test.py >evidence/fresh-postgres-bootstrap.json
./scripts/operator.sh python tests/storage_inventory.py >evidence/storage-inventory.json
.venv/bin/python tests/hardening.py >evidence/hardening.json
.venv/bin/python scripts/restart_events.py >evidence/restart-events.json
.venv/bin/python scripts/container_snapshot.py >evidence/containers-final.json
.venv/bin/python scripts/secret_audit.py >evidence/secret-audit.json
.venv/bin/python scripts/render_report_results.py
printf '%s\n' 'PASS: full lab7 suite completed'