Перейти до вмісту

Сервіс недоступний (5xx / down)

  • Сайт повертає 5xx; API дає помилки; CMS не віддає контент; бот мовчить.
  1. Який саме сервіс? Звір з Сервіси.
  2. Перевір observability stack: Grafana на DO + Telegram-logger чат (TELEGRAM_LOG_CHAT_ID).
  3. Cloudflare показує 5xx → джерело може бути upstream (origin). Не вини CF без перевірки AWS.
Terminal window
# prod ECS
aws ecs describe-services --cluster abitly-prod-frontend --services abitly-prod-frontend \
--profile abitly --region eu-central-1 \
--query 'services[0].{desired:desiredCount,running:runningCount,pending:pendingCount,events:events[0:3]}'
# логи останніх 30 хв
aws logs tail /ecs/abitly-prod-frontend --profile abitly --region eu-central-1 --since 30m

ALB health: aws elbv2 describe-target-health --target-group-arn <abitly-prod-shared frontend TG>.

503 на всіх шляхах + ECS event ResourceInitializationError: … invalid ssm parameters → task-def посилається на видалений SSM-параметр; ECS називає лише перший відсутній — звір повний список secrets проти SSM → інцидент 2026-06-12.

Terminal window
aws ecs describe-services --cluster abitly-prod-backend --services abitly-prod-backend \
--profile abitly --region eu-central-1
aws logs tail /ecs/abitly-prod-backend --profile abitly --region eu-central-1 --since 30m

Часті причини: Postgres недоступний → db-issues; Valkey OOM; Typesense впав.

Terminal window
aws ec2 describe-instance-status --instance-ids i-06c688bb89a71415f --profile abitly --region eu-central-1
aws ssm start-session --target i-06c688bb89a71415f --profile abitly --region eu-central-1
# на інстанції: journalctl -u strapi -n 200 / docker logs

403 від Cloudflare → перевір ORIGIN_CERT (можливо прострочений) → domains-dns.

502 з Caddy + контейнер Strapi у рестарт-лупі (bad variable name в логах entrypoint) → incident-2026-05-28 (SSM-namespace collision з PEM-сертифікатами).

Terminal window
aws elasticbeanstalk describe-environment-health \
--environment-name studsearch-prod-env --attribute-names All \
--profile abitly --region eu-central-1
Terminal window
# здоров'я сервісу/таски
aws ecs describe-services --cluster abitly-prod-backend --services abitly-prod-tg-bot \
--profile abitly --region eu-central-1 \
--query 'services[0].{desired:desiredCount,running:runningCount,pending:pendingCount,events:events[0:3]}'
# логи останніх 30 хв
aws logs tail /abitly-prod/tg-bot --profile abitly --region eu-central-1 --since 30m
# зайти всередину контейнера (ECS Exec)
aws ecs execute-command --cluster abitly-prod-backend --task <task-id> \
--container bot --interactive --command "/bin/sh" --profile abitly --region eu-central-1

Бот мовчить → перевірити healthcheck (GET /healthcheck на :3000) у логах CloudWatch /abitly-prod/tg-bot.

mcp__railway__get-status projectId=6b3a4a23-54c8-41b9-8879-16f97a13779e
mcp__railway__get-logs serviceId=...

Mini App не відкривається → перевірити статус Railway-сервісу та логи деплою.

ПричинаДія
Crash після релізуdeploy-rollback
Впала ECS taskaws ecs update-service --force-new-deployment
ALB unhealthy targetsперевірити health-check path (зазвичай /health) + SG
Strapi 403оновити CF origin-cert у SSM
БД повільнаdb-issues
Cloudflare 522/523upstream down — перевір AWS targets
  • Власник всіх сервісів: @Vladbandurin (single-owner setup).
  • Алерти інфраструктури → Slack workspace.
  • Помилки коду → Telegram TELEGRAM_LOG_CHAT_ID.
  • AWS Support: console → Support Center.
  • Health-checks на ALB / EB / Amplify.
  • Алерти в Grafana → Telegram chat.
  • Staging-перевірка перед prod-deploy.
  • Розглянути HA для Typesense (зараз — один EC2).