Skip to main content

Configuration

Baxela is configured through environment variables at three layers: the compose stack at the repo root, and one .env per app.

Root compose environment (.env)​

These variables drive docker-compose.yml — ports, database credentials, and which profiles start.

VariableDefaultDescription
COMPOSE_PROFILESfrontendCompose profiles to enable; empty for a backend-only stack
BACKEND_APP_PORT8085Host port for the backend (nginx)
REVERB_DEV_PORT8080Host port for the Reverb websocket server
ADMIN_DEV_PORT5173Host port for the admin dev server
STOREFRONT_DEV_PORT3000Host port for the storefront dev server
BACKEND_MYSQL_PORT3308Host port for MySQL
BACKEND_REDIS_PORT6378Host port for Redis
MAILPIT_PORT8025Host port for Mailpit (mail profile)
DEV_DB_DATABASEbaxela_backendDevelop database name
DEV_DB_USERNAMEbaxelaDevelop database user
DEV_DB_PASSWORDpasswordDevelop database password
MYSQL_ROOT_PASSWORDpasswordMySQL root password

Admin panel (apps/admin/.env)​

VariableDescription
VITE_API_BASE_URLBase URL of the Baxela API, e.g. http://localhost:8085/api/v1
VITE_STORE_FRONT_URLStorefront base URL, used for product/page preview links

Storefront (apps/storefront/.env.local)​

VariableDescription
NEXT_PUBLIC_API_BASE_URLBrowser-facing API base URL, e.g. http://localhost:8085/api/v1
SERVER_API_BASE_URLOptional override for server-side (SSR) fetches — inside the compose network this reaches nginx directly (http://web:80/api/v1)

Backend (apps/backend/.env)​

The Laravel application keeps its own .env (database, Redis, mail, Sanctum stateful domains, and so on) exactly like any Laravel app. The develop stack bind-mounts apps/backend into the container, so editing it on the host applies to the running stack.

Notable backend-specific variables:

VariableDescription
CORS_ALLOWED_ORIGINSComma-separated browser origins allowed to call the API (storefront, admin)
STRIPE_SECRETStripe API secret key; the stripe payment method is only offered when it is set
STRIPE_WEBHOOK_SECRETSigning secret for POST /api/v1/payment/webhook/stripe
STRIPE_SUCCESS_URLStorefront return page after hosted checkout ({order_code} templated)
STRIPE_CANCEL_URLStorefront return page for cancelled checkouts
ADMIN_NOTIFICATION_EMAILSComma-separated admin recipients for email notifications (default: mail sender)
ADMIN_NOTIFICATION_USER_IDSRestrict database admin notifications to fixed user ids (default: all staff)
REVERB_APP_ID/_KEY/_SECRETLaravel Reverb credentials for realtime notification broadcasting
VAPID_PUBLIC_KEY/_PRIVATE_KEY/_SUBJECTWeb-push signing keys (php artisan notification:generate-vapid); the channel no-ops when unset

Every additional payment driver (PayPal, Adyen, Mercado Pago, NowPayments, Checkout.com, Razorpay) brings its own credential block — see Payment flow for the full per-driver variable tables. The shared-hosting deploy tool keeps its connection settings in .env.sharedhosting at the repo root (see Shared hosting).