iachat/bin
Rodribm10 280d250983 feat(captain/hermes): script hermes-provision pra Construtor autônomo
Bash script em bin/hermes-provision (instalado em /usr/local/bin/ na VPS)
que recebe spec JSON via stdin e provisiona um agente Hermes ponta-a-ponta:
- Valida spec (slug regex, preços 0-5000, períodos/buckets do catálogo)
- Aloca porta livre no range 8650-8699
- Gera HMAC secret via openssl rand
- Cria Captain::Unit (find_or_create), Captain::PricingCategory/Amount,
  Captain::Assistant (engine=hermes) via docker exec rails runner
- Copia template profile da Valentina, patcheia config.yaml com porta +
  X-Captain-Assistant-Id (parent_id se setado, senão self id)
- Escreve SOUL.md/SKILL.md do spec
- Gera webhook_subscriptions.json com secret
- Cria systemd unit hermes@<slug>.service e enable+start
- rsync profile pra repo de backup git local
- Idempotente: re-rodar com mesmo slug não duplica nada (find_or_create)
- --dry-run valida sem escrever
- --rollback <slug> destrói tudo (DB + systemd + filesystem)

Construtor (Hermes daemon) chama via terminal skill nativa:
  echo '<spec>' | /usr/local/bin/hermes-provision

Próximo passo: atualizar SOUL.md/SKILL.md do Construtor pra invocar
o script ao final do fluxo socrático.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-02 09:59:30 -03:00
..
bundle feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
hermes-provision feat(captain/hermes): script hermes-provision pra Construtor autônomo 2026-05-02 09:59:30 -03:00
rails Upgrade to rails 6 💎 (#11) 2019-08-19 13:49:57 +05:30
rake Upgrade to rails 6 💎 (#11) 2019-08-19 13:49:57 +05:30
setup Upgrade to rails 6 💎 (#11) 2019-08-19 13:49:57 +05:30
spring 🚨Fix Rubocop lint errors 2019-10-20 14:17:26 +05:30
sync_i18n_file_change chore: Update translations, add pnpm sync:i18n command (#10893) 2025-02-12 17:43:46 -08:00
update chore: Set statement timeout for Postgres (#6641) 2023-03-13 18:34:18 +05:30
validate_push chore: Upgrade to Rails 7 (#6719) 2023-05-06 10:44:52 +05:30
vite feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
yarn 🚨Fix Rubocop lint errors 2019-10-20 14:17:26 +05:30