openvibers/openvibe.community .env.example
.env.example
| 1 | # ═══════════════════════════════════════════════════════════════ |
| 2 | # openvibe.community — Environment Configuration |
| 3 | # Copy to .env and fill in values. |
| 4 | # In production this lives at /etc/openvibe/community.env (0600). |
| 5 | # ═══════════════════════════════════════════════════════════════ |
| 6 | |
| 7 | # Server |
| 8 | PORT=4200 |
| 9 | HOST=127.0.0.1 |
| 10 | NODE_ENV=development |
| 11 | BASE_URL=http://localhost:4200 |
| 12 | # Proxy hops that set X-Forwarded-For (Cloudflare → nginx → Node = 2) |
| 13 | TRUST_PROXY=2 |
| 14 | |
| 15 | # Identity provider — OpenVibe.Network (OAuth2 authorization server + JWKS) |
| 16 | OV_NETWORK_URL=https://openvibe.network |
| 17 | OV_NETWORK_INTERNAL_URL=http://127.0.0.1:4000 |
| 18 | |
| 19 | # OAuth2 client credentials (client `community` registered in the Network DB, |
| 20 | # redirect https://openvibe.community/auth/callback) |
| 21 | OV_OAUTH_CLIENT_ID=community |
| 22 | OV_OAUTH_CLIENT_SECRET=change-me-to-the-registered-community-secret |
| 23 | # Production: https://openvibe.community/auth/callback |
| 24 | OV_OAUTH_REDIRECT_URI=http://localhost:4200/auth/callback |
| 25 | |
| 26 | # Cookies — production default is Secure; set false for plain-http local dev |
| 27 | #COOKIE_SECURE=false |
| 28 | |
| 29 | # OpenVibe.Live — author links, avatars and legal pages (no paste traffic). |
| 30 | |
| 31 | OV_LIVE_URL=https://openvibe.live |
| 32 | |
| 33 | # OpenVibe.Media — public host for screenshot bytes |
| 34 | OV_MEDIA_URL=https://openvibe.media |
| 35 | # Media's internal address: new screenshot uploads go to its file store |
| 36 | # with a service token (the OAuth client needs media.object.upload for audience openvibe.media). |
| 37 | OV_MEDIA_INTERNAL_URL=http://127.0.0.1:4100 |
| 38 | |
| 39 | # OpenVibe.VIP: members-only forum spaces and threads. Community asks POST /api/v1/policies/evaluate |
| 40 | # with a service token (the OAuth client needs vip.resource.policy.evaluate for audience openvibe.vip). |
| 41 | # Without it, or with VIP down, only the owner and moderators get in (fails closed). |
| 42 | OV_VIP_INTERNAL_URL=http://127.0.0.1:4620 |
| 43 | OV_VIP_URL=https://openvibe.vip |
| 44 | |
| 45 | # OpenVibe.Chat: a space's chat room. Community asks Chat with the signed-in person's own token whether |
| 46 | # they manage the room (no service grant needed); the space page links OV_CHAT_URL/r/<room>. |
| 47 | OV_CHAT_INTERNAL_URL=http://127.0.0.1:4400 |
| 48 | OV_CHAT_URL=https://openvibe.chat |
| 49 | # How long a VIP yes / no / failure is cached (ms); the yes TTL bounds how long access outlives a membership. |
| 50 | # VIP_CACHE_TTL_MS=30000 |
| 51 | # VIP_CACHE_DENY_TTL_MS=10000 |
| 52 | # VIP_CACHE_UNAVAILABLE_TTL_MS=2000 |
| 53 | |
| 54 | # Pastes are Community's own (native API, pages, raw text); the OAuth client above also needs |
| 55 | # identity.subject.resolve (author names). |
| 56 | |
| 57 | # PostgreSQL (ADR-035), written by OpenVibe.Host roles/data/add-service.sh community: the runtime role through |
| 58 | # PgBouncer, the owner on a direct connection (migrations), and Valkey (shared limit counters). Pastes, comments, |
| 59 | # the forum, Pulse and the relay's bookkeeping live there. Without |
| 60 | # DATABASE_URL, development uses an embedded PGlite database in data/pglite. |
| 61 | DATABASE_URL= |
| 62 | DATABASE_DIRECT_URL= |
| 63 | VALKEY_URL= |
| 64 | VALKEY_PREFIX= |
| 65 | # Optional salt for hashed visitor ids in view counting (default: derived from the client secret) |
| 66 | #VIEW_HASH_SECRET= |
| 67 | |
| 68 | # Per-actor limits (server/actor-limits.js): reads one caller (a person, a service or app acting as |
| 69 | # itself, else an address) may make to one API per minute and per hour; past them 429 rate_limited |
| 70 | # with Retry-After. Writes have their own numbers (README). The per-address /api/ limit stays. |
| 71 | #COMMUNITY_LIMITS_MINUTE=120 |
| 72 | #COMMUNITY_LIMITS_HOUR=3000 |
| 73 | |
| 74 | # Browser origins allowed to call /api/v1/comments and /api/v1/pulse with a Bearer Network JWT |
| 75 | #API_CORS_ORIGINS=https://openvibe.live,https://openvibe.media,https://openvibe.network,https://openvibe.tools,https://openvibe.games |
| 76 | |
| 77 | # Discord relay (outbound: new threads in mapped spaces → a Discord webhook). Off by default. |
| 78 | # Mappings (POST /api/v1/relay/mappings, staff) name an ENVIRONMENT VARIABLE that holds the |
| 79 | # webhook URL — the URL itself never goes into the database. |
| 80 | #DISCORD_RELAY_ENABLED=true |
| 81 | #DISCORD_WEBHOOK_FEEDBACK=https://discord.com/api/webhooks/<id>/<token> |
| 82 | # Variables a mapping may name: DISCORD_WEBHOOK_* unless this lists the exact names. |
| 83 | #DISCORD_RELAY_WEBHOOK_VARS=DISCORD_WEBHOOK_FEEDBACK,DISCORD_WEBHOOK_GENERAL |
| 84 | #DISCORD_RELAY_POLL_MS=30000 |
| 85 | #DISCORD_RELAY_BACKOFF_MS=30000 |
| 86 | #DISCORD_RELAY_MAX_ATTEMPTS=6 |
| 87 |