mirror of
https://github.com/domfelipe/mika-agent-assist.git
synced 2026-08-07 06:16:42 +00:00
Changes
Co-authored-by: domfelipe <53182096+domfelipe@users.noreply.github.com>
This commit is contained in:
parent
238cbe8494
commit
89a32a1f6e
1 changed files with 15 additions and 0 deletions
15
README.md
15
README.md
|
|
@ -39,6 +39,21 @@ Já configuradas via `.env` (gerado automaticamente pelo Lovable Cloud):
|
|||
- `ADMIN_TELEGRAM_CHAT_ID` — chat ID do admin que recebe as notificações (ex: `179720882`).
|
||||
- (opcional, Fase 5) credenciais SSH para Hermes
|
||||
|
||||
## Keep-alive dos agentes (substitui UptimeRobot)
|
||||
|
||||
A Edge Function `keep-alive-agents` mantém todos os containers Railway ativos automaticamente — **não há nada para configurar por agente**. A cada 4 minutos:
|
||||
|
||||
1. Carrega todos os `agent_instances` com `status = 'active'` e `telegram_bot_token_vault_id` preenchido.
|
||||
2. Faz `GET https://api.telegram.org/bot{token}/getMe` para cada um (em paralelo, com falhas isoladas).
|
||||
3. Esse tráfego de saída do container Hermes evita que o Railway hiberne instâncias ociosas.
|
||||
|
||||
Agendado via `pg_cron` (job `keep-alive-agents-every-4min`, schedule `*/4 * * * *`). Consultar/desagendar:
|
||||
|
||||
```sql
|
||||
SELECT * FROM cron.job WHERE jobname = 'keep-alive-agents-every-4min';
|
||||
SELECT cron.unschedule('keep-alive-agents-every-4min');
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Fase 3 — Telegram Onboarding (✅ entregue)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue