Spaces:
Running

File size: 1,768 Bytes
77db408
 
 
 
 
 
b15ebfe
 
 
 
 
 
 
 
 
 
 
 
 
77db408
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
@echo off
rem Template for local secrets. Copy to run-local.secrets.cmd (gitignored)
rem and fill in the real values. Used for the signup-approval emails.
rem Without this file the app still works — approval emails are only
rem written to the backend log, and you can approve from Admin -> Users.

rem Gmail API (same transport as the HF Space): the three values printed by
rem backend\scripts\gmail_refresh_token.py. Takes precedence over SMTP.
set GMAIL_CLIENT_ID=xxxx.apps.googleusercontent.com
set GMAIL_CLIENT_SECRET=GOCSPX-xxxx
set GMAIL_REFRESH_TOKEN=1//xxxx
set "SMTP_FROM=Gateway Hub <seu-email@gmail.com>"

rem SMTP fallback (local only - HF blocks SMTP): smtp.gmail.com + an App
rem Password from https://myaccount.google.com/apppasswords (needs 2FA on).
rem set SMTP_HOST=smtp.gmail.com
rem set SMTP_PORT=587
rem set SMTP_USER=seu-email@gmail.com
rem set SMTP_PASSWORD=xxxx xxxx xxxx xxxx

rem Who receives the "account request" notifications (default: every active
rem admin user in the DB — set this to override).
rem set ADMIN_NOTIFY_EMAIL=seu-email@gmail.com

rem Public base URL used in the approve/reject links (default: first
rem ALLOWED_ORIGINS entry, i.e. http://localhost:3000 in local dev).
rem set APP_PUBLIC_URL=https://seu-erp-publico.example.com

rem — Postgres (Neon) — usado SÓ pelo script de migração de dados
rem (backend\scripts\migrate_sqlite_to_pg.py). NÃO defina DATABASE_URL aqui:
rem isso apontaria o dev local direto para o banco de PRODUÇÃO.
rem IMPORTANTE: use a forma set "VAR=..." (com aspas) — a URL contém '&',
rem que sem aspas o cmd interpreta como separador de comando.
rem set "NEON_DATABASE_URL=postgresql://usuario:senha@ep-xxxx.us-east-2.aws.neon.tech/neondb?sslmode=require&channel_binding=require"