gohorsejobs/docs
Tiago Yamamoto 89358acc13 refactor(auth): remove hash hardcoded da migration, seeder gera em runtime
Antes: 010_seed_super_admin.sql tinha hash bcrypt fixo amarrado a um pepper
específico. Qualquer mudança no PASSWORD_PEPPER quebrava todos os logins
silenciosamente após reset do banco.

Agora:
- migration 010: insere superadmin com placeholder inválido + force_change_password.
  ON CONFLICT DO NOTHING preserva o hash se o seeder já rodou.
- seeder users.js: faz upsert de 'lol' com bcrypt(senha + env.PASSWORD_PEPPER)
  em runtime. Mudar o pepper e re-rodar o seeder é suficiente para atualizar
  as credenciais sem tocar em nenhuma migration.
- docs/AGENTS.md: atualiza gotcha #1 explicando o novo fluxo migrate → seed
- docs/DEVOPS.md: fix opção 1 do troubleshooting inclui re-deploy do seeder

Fluxo correto após reset do banco (coberto pelo start.sh opções 2, 6, 8):
  npm run migrate  →  superadmin criado, hash = placeholder
  npm run seed     →  hash recalculado com PEPPER do ambiente, status = active

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-22 12:05:54 -06:00
..
txt test: increase backend use case coverage 2026-02-16 23:25:26 -03:00
AGENTS.md refactor(auth): remove hash hardcoded da migration, seeder gera em runtime 2026-02-22 12:05:54 -06:00
API.md docs: unify test users in root README and update superadmin to lol login 2026-02-21 14:48:25 -06:00
API_SECURITY.md docs: unify documentation structure 2026-02-16 05:57:02 -06:00
BACKEND_COVERAGE.md feat: add test coverage and handler improvements 2026-01-02 08:50:29 -03:00
CAREERJET_GAP_ANALYSIS.md docs: add codex fast-track execution plan for careerjet gaps 2026-02-14 17:37:54 -03:00
CLOUDFLARE.md docs: add Cloudflare zone info and DNS management agent 2026-02-16 20:33:20 -06:00
DATABASE.md docs: unify documentation structure 2026-02-16 05:57:02 -06:00
DEVOPS.md refactor(auth): remove hash hardcoded da migration, seeder gera em runtime 2026-02-22 12:05:54 -06:00
FULL_TEST_REPORT.md feat: add test coverage and handler improvements 2026-01-02 08:50:29 -03:00
GUIA_MIGRACAO_FORGEJO.md feat: atualiza fluxo de cadastro de candidatos com persistência completa de dados e máscara de telefone 2026-01-06 18:19:47 -03:00
publicar-vaga-routes.md refactor job posting routes and add dashboard job creation page 2026-02-17 09:42:31 -03:00
README.md docs: add AI context rules and missing READMEs 2026-02-21 13:33:36 -06:00
ROADMAP.md docs: unifica documentação e atualiza README principal 2026-02-14 17:07:11 -03:00
TASKS.md refactor job posting routes and add dashboard job creation page 2026-02-17 09:42:31 -03:00
TEST_REPORT.md feat: add test coverage and handler improvements 2026-01-02 08:50:29 -03:00
TEST_USERS.md docs: unify test users in root README and update superadmin to lol login 2026-02-21 14:48:25 -06:00
WORKFLOWS.md docs: unify documentation structure 2026-02-16 05:57:02 -06:00

Project Documentation - GoHorse Jobs

This directory holds internal team documentation, guides, and extended context regarding project structure and architecture.

🚨 AI Rules Warning 🚨

Before making ANY changes to infrastructure deployment manifests or Kubernetes files, please refer to the project-wide AI Rules located at .agent/rules.md. Do NOT touch k3s or k8s files. Do not alter raw RSA/base64 authentication keys.