Dashboard Setup
Deploy the Grovs dashboard and connect it to your self-hosted backend.
The Grovs dashboard is a Next.js application that provides a web interface for managing links, viewing analytics, and configuring your projects. This guide covers deploying it alongside your self-hosted backend.
Prerequisites
- The backend is deployed and running
- You have the OAuth Client ID and Client Secret from the backend setup
- Docker and Docker Compose installed (or Node.js 20+ for local builds)
Clone the repository
git clone https://github.com/grovs-io/dashboard.git
cd dashboardCreate the environment file
cp .env.example .env.localEdit .env.local with your backend connection details:
# Point to your self-hosted backend API
NEXT_PUBLIC_API_URL=https://api.yourdomain.com
NEXT_PUBLIC_API_PATH=/api/v1
# OAuth credentials from the backend setup
NEXT_PUBLIC_CLIENT_ID=your_oauth_client_id
CLIENT_SECRET=your_oauth_client_secretThe NEXT_PUBLIC_CLIENT_ID and CLIENT_SECRET come from the OAuth application created during the backend database seed step. If you need to retrieve them again, run docker compose exec web bundle exec rails console in the backend directory and execute Doorkeeper::Application.first.
Start with Docker Compose
docker compose up --buildThe dashboard will be available at http://localhost:3036.
Or start with Node.js directly:
npm install
npm run build
npm startThe dashboard will be available at http://localhost:3001.
Create your account
Open the dashboard in your browser and sign up for a new account. Since this is a self-hosted instance, the first account you create will be your admin account.
Environment variables reference
Required
| Variable | Description | Example |
|---|---|---|
NEXT_PUBLIC_API_URL | Backend API base URL | https://api.yourdomain.com |
NEXT_PUBLIC_API_PATH | API path prefix | /api/v1 |
NEXT_PUBLIC_CLIENT_ID | OAuth application client ID | From backend seeds |
CLIENT_SECRET | OAuth application client secret | From backend seeds |
Optional
| Variable | Description |
|---|---|
NEXT_PUBLIC_ENV | Environment name (production, test) |
NEXT_PUBLIC_GROVS_EE | Set to true to enable enterprise features (revenue tracking) |
NEXT_PUBLIC_POSTHOG_KEY | PostHog analytics key |
NEXT_PUBLIC_GTM_ID | Google Tag Manager ID |
NEXT_PUBLIC_CHATWOOT_URL, NEXT_PUBLIC_CHATWOOT_TOKEN | Chatwoot live chat |
NEXT_PUBLIC_FIREBASE_* | Firebase configuration (analytics only) |
All optional integrations are gracefully disabled when their environment variables are not set. A minimal deployment only needs the four required variables.
Running behind a reverse proxy
If you serve the dashboard behind nginx, Caddy, or another reverse proxy, point your dashboard domain (e.g. app.yourdomain.com) to the container port:
# nginx example
server {
server_name app.yourdomain.com;
location / {
proxy_pass http://localhost:3036;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}