Files
mtusi2026lab7/.github/workflows/app.yml
T
sendormeco d15f2a3631
Application stack (lab7) / stack (pull_request) Canceled after 0s
Skeleton contracts / contracts (pull_request) Canceled after 0s
7 — Т2302 — ебедев — на 5
2026-11-22 23:26:17 +03:00

56 lines
2.9 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
name: Application stack (lab7)
# Отдельный job решения: локальные synthetic secrets + PKI → OpenBao (non-dev: init/unseal/bootstrap) → весь стенд
# (LB + 2 API + 2 worker + PostgreSQL + Redis + S3 + NATS + Collector/Prometheus/Loki/Tempo/Grafana, всё через TLS/mTLS),
# публичные smoke/security по HTTPS с CA (без отключения проверки), внутренняя матрица доверия, hardening, lifecycle
# (ротации под нагрузкой, sealed OpenBao), failover/persistence, трек 1. Секреты генерируются на лету и не сохраняются.
on: [push, pull_request]
permissions:
contents: read
env:
NO_PROXY: 127.0.0.1,localhost
BASE_URL: https://127.0.0.1:8443
jobs:
stack:
runs-on: ubuntu-24.04
timeout-minutes: 120
steps:
- uses: actions/checkout@v4
- name: Secrets, PKI and .env (synthetic, local only)
run: ./scripts/init-secrets.sh
- name: Compose config
run: docker compose --env-file .env --profile ttl --profile tools --profile tests config --quiet
- name: OpenBao init/unseal/bootstrap and start the stack
run: PROFILES="--profile ttl" ./scripts/up.sh && docker compose --env-file .env --profile tools up -d ops
- name: Public smoke and external TLS trust (HTTPS + CA)
run: |
make test BASE_URL=$BASE_URL CA_FILE=$PWD/secrets/tls/trust/ca.crt
make test-security BASE_URL=$BASE_URL CA_FILE=$PWD/secrets/tls/trust/ca.crt
- name: Internal trust matrix (mTLS identities, ACL, policies, TLS audit)
run: make test-internal
- name: External boundary, ACL, rate limits, Argon2id
run: make test-student-security
- name: Hardening (privileges, ports, secrets outside env/images/telemetry)
run: make test-hardening
- name: Regression lab2–lab6
run: make test-student
- name: Failover (stop one API replica), then restore
run: |
make test-failover ACTION_SCRIPT=scripts/stop-one.sh BASE_URL=$BASE_URL
./scripts/start-replicas.sh
- name: Persistence (restart LB, API, worker, all stores incl. OpenBao + unseal; volumes kept)
run: make test-persistence ACTION_SCRIPT=scripts/restart.sh BASE_URL=$BASE_URL
- name: Lifecycle under load (DB/S3/cert rotation, sealed OpenBao, tokens, renewal)
run: make test-lifecycle
- name: Track 1 (worker compromise) and login DoS budget
run: |
make track1
make login-dos
- name: Secret scan (repository + evidence)
run: make secret-scan
- name: Logs on failure
if: failure()
run: docker compose --env-file .env --profile ttl --profile fault --profile tools logs --no-color --tail=200
- name: Stop and delete synthetic data
if: always()
run: FORCE=1 ./scripts/reset.sh