Frontend Setup
Prerequisites
- Node.js 16+ and npm
- A running Backend instance (default:
http://localhost:8080)
Running Locally
- Clone the monorepo and enter the frontend app:
git clone https://github.com/qlarr-surveys/qlarr.git && cd qlarr/frontend
- Install dependencies:
npm install
- Point the app at the backend via
VITE_*environment variables (e.g. in a.envfile):
VITE_PROTOCOL=http
VITE_FRONT_END_HOST=localhost:3000
VITE_BE_URL=http://localhost:8080
- Start the development server:
npm start
The app will be available at http://localhost:3000. Log in with the default admin account from the backend: admin@admin.admin / admin.
Building for Production
npm run build
The output is written to the build/ directory.
Docker
The production Docker image uses Caddy as the web server:
docker build -t qlarr-frontend .
docker run -p 80:80 qlarr-frontend
The entrypoint.sh script handles runtime configuration injection so the same image can be deployed to different environments.