diff --git a/.github/workflows/station-status-freshness.yml b/.github/workflows/station-status-freshness.yml index 7f5b53a..d585a89 100644 --- a/.github/workflows/station-status-freshness.yml +++ b/.github/workflows/station-status-freshness.yml @@ -1,6 +1,13 @@ name: Station Status Freshness on: + push: + branches: + - master + paths: + - "Petabit/Models/StationStatus.cs" + - "Petabit.Tests/StationStatusTests.cs" + - ".github/workflows/station-status-freshness.yml" schedule: - cron: "0 7 * * 1" workflow_dispatch: diff --git a/.github/workflows/uptime.yml b/.github/workflows/uptime.yml index bf5a46e..aff8e69 100644 --- a/.github/workflows/uptime.yml +++ b/.github/workflows/uptime.yml @@ -1,9 +1,6 @@ name: Uptime Monitor on: - push: - branches: - - master workflow_dispatch: permissions: @@ -21,12 +18,9 @@ jobs: env: SITE_URL: https://petabit-production.up.railway.app - MAX_ATTEMPTS: ${{ github.event_name == 'push' && '8' || '3' }} + MAX_ATTEMPTS: 3 steps: - - name: Allow Railway deployment to start - if: github.event_name == 'push' - run: sleep 90 - name: Wait for production liveness run: | diff --git a/README.md b/README.md index 3e62ed3..c53fbd7 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,6 @@ [![CI](https://github.com/ChevCellios/Petabit/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/ChevCellios/Petabit/actions/workflows/ci.yml) [![Security](https://github.com/ChevCellios/Petabit/actions/workflows/security.yml/badge.svg?branch=master)](https://github.com/ChevCellios/Petabit/actions/workflows/security.yml) -[![Production smoke test](https://github.com/ChevCellios/Petabit/actions/workflows/uptime.yml/badge.svg?branch=master)](https://github.com/ChevCellios/Petabit/actions/workflows/uptime.yml) [![Station status freshness](https://github.com/ChevCellios/Petabit/actions/workflows/station-status-freshness.yml/badge.svg?branch=master)](https://github.com/ChevCellios/Petabit/actions/workflows/station-status-freshness.yml) [![Monitored by Better Stack](https://img.shields.io/badge/uptime-Better%20Stack-5B45FF)](https://betterstack.com/uptime) ![.NET](https://img.shields.io/badge/.NET-10.0-blueviolet) @@ -65,10 +64,10 @@ Izvori podataka: - timeout, retry i circuit breaker za vanjski ISS servis - `/health/live` provjera procesa i `/health/ready` provjera dostupnosti ISS servisa -- post-deployment smoke test nakon svakog pusha u `master` -- Better Stack provjera produkcijskih liveness, readiness i ISS API endpointova svake 3 minute +- ručno pokretljiv GitHub produkcijski smoke test za ciljanu dijagnostiku +- Better Stack provjera produkcijskog liveness endpointa svakih 10 minuta - tjedna provjera starosti kuriranih podataka o ISS posadi i letjelicama -- smoke test početne stranice, readiness endpointa i ISS trackera +- ručni smoke test početne stranice, readiness endpointa i ISS trackera - strukturirani JSON logovi u produkciji - validirani `X-Correlation-ID` za povezivanje korisničkog zahtjeva s Railway logovima - sigurna produkcijska error stranica bez izlaganja detalja iznimke @@ -91,7 +90,7 @@ Grana `master` zaštićena je pull request pravilima i zahtijeva prolazak sljede - `Audit NuGet dependencies` - `Analyze C# with CodeQL` -Nakon mergea Railway automatski deploya novu verziju, a produkcijski smoke test potvrđuje dostupnost aplikacije. +Nakon mergea Railway automatski deploya novu verziju. Better Stack nadzire liveness svakih 10 minuta, a puni produkcijski smoke test pokreće se ručno kada je potrebna ciljana provjera. ## ✅ Testiranje